@Override public Boolean get(long duration, TimeUnit units) throws InterruptedException, TimeoutException, ExecutionException { status = new OperationStatus(true, "OK", StatusCode.SUCCESS); return super.get(duration, units); }
@Override public T get() throws InterruptedException, ExecutionException { try { return get(timeout, TimeUnit.MILLISECONDS); } catch (TimeoutException e) { status = new OperationStatus(false, "Timed out"); throw new RuntimeException("Timed out waiting for operation", e); } }
@Override public Boolean get(long duration, TimeUnit units) throws InterruptedException, TimeoutException, ExecutionException { status = new OperationStatus(true, "OK"); return super.get(duration, units); }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus(new OperationStatus(true, new String(pl), StatusCode.SUCCESS)); } }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus(new OperationStatus(true, new String(pl))); } }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus(new OperationStatus(true, new String(pl), StatusCode.SUCCESS)); }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus(new OperationStatus(true, new String(pl), StatusCode.SUCCESS)); } }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus( new OperationStatus(true, new String(pl))); }
@Override public void handleLine(String line) { assert line.startsWith("VERSION "); getCallback().receivedStatus( new OperationStatus(true, line.substring("VERSION ".length()))); transitionState(OperationState.COMPLETE); }
@Override public void handleLine(String line) { assert line.startsWith("VERSION "); getCallback().receivedStatus(new OperationStatus(true, line.substring("VERSION ".length()), StatusCode.SUCCESS)); transitionState(OperationState.COMPLETE); }
@Override public void handleLine(String line) { assert line.startsWith("VERSION "); getCallback().receivedStatus( new OperationStatus(true, line.substring("VERSION ".length()))); transitionState(OperationState.COMPLETE); }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus(new OperationStatus(true, String.valueOf(decodeLong(pl, 0)), StatusCode.SUCCESS)); }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus(new OperationStatus(true, String.valueOf(decodeLong(pl, 0)))); }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus( new OperationStatus(true, String.valueOf(decodeLong(pl, 0)))); }
@Override protected void decodePayload(byte[] pl) { getCallback().receivedStatus(new OperationStatus(true, String.valueOf(decodeLong(pl, 0)))); }
@Override protected void finishedPayload(byte[] pl) throws IOException { if (errorCode == SASL_CONTINUE) { getCallback().receivedStatus(new OperationStatus(true, new String(pl))); transitionState(OperationState.COMPLETE); } else if (errorCode == 0) { getCallback().receivedStatus(new OperationStatus(true, "")); transitionState(OperationState.COMPLETE); } else { super.finishedPayload(pl); } }
@Override public void handleLine(String line) { getLogger().debug("Result: %s", line); OperationStatus found = null; if (line.equals("NOT_FOUND")) { found = NOT_FOUND; } else { found = new OperationStatus(true, line); } getCallback().receivedStatus(found); transitionState(OperationState.COMPLETE); }
@Override public void handleLine(String line) { getLogger().debug("Result: %s", line); OperationStatus found=null; if(line.equals("NOT_FOUND")) { found=NOT_FOUND; } else { found=new OperationStatus(true, line); } getCallback().receivedStatus(found); transitionState(OperationState.COMPLETE); }
@Override public void handleLine(String line) { getLogger().debug("Result: %s", line); OperationStatus found=null; if(line.equals("NOT_FOUND")) { found=NOT_FOUND; } else { found=new OperationStatus(true, line); } getCallback().receivedStatus(found); transitionState(OperationState.COMPLETE); }
@Override public void handleLine(String line) { getLogger().debug("Result: %s", line); OperationStatus found = null; if (line.equals("NOT_FOUND")) { found = NOT_FOUND; } else { found = new OperationStatus(true, line, StatusCode.SUCCESS); } getCallback().receivedStatus(found); transitionState(OperationState.COMPLETE); }