Code example for Future

Methods: cancelget

0
	} 
 
	@Override 
	public Void call() throws ExecutionException, InterruptedException {
		try { 
			future.get(timeout, unit);
		} catch (TimeoutException te) {
			future.cancel(true);
		} 
		return null; 
	} 
 
} 
Stop searching for code, let great code find you!  Add Codota to your java IDE