public com.quickserverlab.quickcached.client.CASValue gets(String key, long timeoutMiliSec) 
			throws TimeoutException, com.quickserverlab.quickcached.client.MemcachedException{
		com.quickserverlab.quickcached.client.CASValue value = null;
		try{
			OperationFuture <CASValue<Object>> f =  getCache().asyncGets(key);
			try {
				CASValue<Object> cv = (CASValue<Object>) f.get(timeoutMiliSec, TimeUnit.MILLISECONDS);
				if(cv != null){
					value = new com.quickserverlab.quickcached.client.CASValue(cv.getCas(), cv.getValue());
				}else{
					throw new com.quickserverlab.quickcached.client.MemcachedException("Object not found");
				}
			}catch(InterruptedException ie){
				throw new com.quickserverlab.quickcached.client.MemcachedException("InterruptedException "+ ie);
			}catch(ExecutionException ee){
				throw new com.quickserverlab.quickcached.client.MemcachedException("ExecutionException "+ ee);
			}catch(java.util.concurrent.TimeoutException te){
				throw new TimeoutException("Timeout "+ te);
			}finally{
				f.cancel(false);
			}
		}catch(IllegalStateException ise){
			throw new com.quickserverlab.quickcached.client.MemcachedException("IllegalStateException "+ ise);
		}
		return value;				
	}