protected Object doCall() throws Exception { context.getProtocolChain().execute(context); return null; }
/** * Delegate the processing of the read operation to the {@link IOEvent{ * associated {@link ProtocolChain} * @param ioEvent an {@link IOEvent} representing the current state of the * OP_CONNECT operations. */ public void onRead(IOEvent<Context> ioEvent) { if (!delegateToProtocolChain) return; Context context = ioEvent.attachment(); try { context.getProtocolChain().execute(context); } catch (Exception ex) { Controller.logger().log(Level.SEVERE, "Read/Write operation failed.", ex); } }
public boolean handle(Context context, PUProtocolRequest protocolRequest) throws IOException { ProtocolChain protocolChain = pcih.poll(); try { try { protocolChain.execute(context); } catch (Exception e) { Controller.logger().log(Level.WARNING, "Error executing custom filter chain", e); } } finally { pcih.offer(protocolChain); } return context.getKeyRegistrationState() != Context.KeyRegistrationState.CANCEL; }