/** * Indicates that the next action is to flip the processing direction * and starts response processing. */ public void returnWith( Packet response ) { set(RETURN, null, response, null); }
/** * Indicates that the next action is to abort the processResponse chain * because of some non-exception condition. * * @param response The response that is being aborted */ public void abortResponse(Packet response) { set(ABORT_RESPONSE,null,response,null); }
/** * Indicates that the next action is to flip the processing direction * and starts response processing. */ public void returnWith( Packet response ) { set(RETURN, null, response, null); }
/** * Indicates that the next action is to abort the processResponse chain * because of an exception. How that exception is processed is not * defined. * * @param t * Either {@link RuntimeException} or {@link Error} */ public void throwExceptionAbortResponse(Throwable t) { set(THROW_ABORT_RESPONSE,null,null,t); }
/** * Indicates that the next action is to abort the processResponse chain * because of some non-exception condition. * * @param response The response that is being aborted */ public void abortResponse(Packet response) { set(ABORT_RESPONSE,null,response,null); }
/** * Indicates that the next action is to invoke the next tube in the * tubeline async from the thread that started the tubeline. Only fibers * that were started using startSync should use this next action kind. * @param next The next tube in the tubeline * @param p The request to pass to the next tube */ public void invokeAsync(Tube next, Packet p) { set(INVOKE_ASYNC,next,p,null); }
/** * Indicates that the next action should be to * invoke the next tube's {@link Tube#processRequest(Packet)}, * then later invoke the current tube's {@link Tube#processResponse(Packet)} * with the response packet. */ public void invoke(Tube next, Packet p) { set(INVOKE, next, p, null); }
/** * Indicates that the next action is to abort the processResponse chain * because of an exception. How that exception is processed is not * defined. * * @param t * Either {@link RuntimeException} or {@link Error} */ public void throwExceptionAbortResponse(Throwable t) { set(THROW_ABORT_RESPONSE,null,null,t); }
/** * Indicates that the next action should be to * invoke the next tube's {@link Tube#processRequest(Packet)}, * then later invoke the current tube's {@link Tube#processResponse(Packet)} * with the response packet. */ public void invoke(Tube next, Packet p) { set(INVOKE, next, p, null); }
/** * Indicates that the next action should be to * invoke the next tube's {@link Tube#processRequest(Packet)}, * then later invoke the current tube's {@link Tube#processResponse(Packet)} * with the response packet. */ public void invoke(Tube next, Packet p) { set(INVOKE, next, p, null); }
/** * Indicates that the next action should be to * invoke the next tube's {@link Tube#processRequest(Packet)}, * but the current tube doesn't want to receive the response packet to * its {@link Tube#processResponse(Packet)}. */ public void invokeAndForget(Tube next, Packet p) { set(INVOKE_AND_FORGET, next, p, null); }
/** * Indicates that the next action is to abort the processResponse chain * because of some non-exception condition. * * @param response The response that is being aborted */ public void abortResponse(Packet response) { set(ABORT_RESPONSE,null,response,null); }
/** * Indicates that the next action is to invoke the next tube in the * tubeline async from the thread that started the tubeline. Only fibers * that were started using startSync should use this next action kind. * @param next The next tube in the tubeline * @param p The request to pass to the next tube */ public void invokeAsync(Tube next, Packet p) { set(INVOKE_ASYNC,next,p,null); }
/** * Indicates that the next action should be to * invoke the next tube's {@link Tube#processRequest(Packet)}, * but the current tube doesn't want to receive the response packet to * its {@link Tube#processResponse(Packet)}. */ public void invokeAndForget(Tube next, Packet p) { set(INVOKE_AND_FORGET, next, p, null); }
/** * Indicates that the next action is to invoke the next tube in the * tubeline async from the thread that started the tubeline. Only fibers * that were started using startSync should use this next action kind. * @param next The next tube in the tubeline * @param p The request to pass to the next tube */ public void invokeAsync(Tube next, Packet p) { set(INVOKE_ASYNC,next,p,null); }
/** * Indicates that the next action is to flip the processing direction * and starts exception processing, but with the indicated context. * * @param t * Either {@link RuntimeException} or {@link Error}, but defined to * take {@link Throwable} because {@link Tube#processException(Throwable)} * takes {@link Throwable}. */ public void throwException( Packet response, Throwable t ) { // Use of RETURN is correct -- Fiber processing does not set packet for type of THROW set(RETURN, null, response, t); }
/** * Indicates that the next action should be to * invoke the next tube's {@link Tube#processRequest(Packet)}, * but the current tube doesn't want to receive the response packet to * its {@link Tube#processResponse(Packet)}. */ public void invokeAndForget(Tube next, Packet p) { set(INVOKE_AND_FORGET, next, p, null); }
/** * Indicates that the next action is to flip the processing direction * and starts response processing. */ public void returnWith( Packet response ) { set(RETURN, null, response, null); }
/** * Indicates that the next action is to abort the processResponse chain * because of an exception. How that exception is processed is not * defined. * * @param t * Either {@link RuntimeException} or {@link Error} */ public void throwExceptionAbortResponse(Throwable t) { set(THROW_ABORT_RESPONSE,null,null,t); }
/** * Indicates that the next action is to flip the processing direction * and starts exception processing, but with the indicated context. * * @param t * Either {@link RuntimeException} or {@link Error}, but defined to * take {@link Throwable} because {@link Tube#processException(Throwable)} * takes {@link Throwable}. */ public void throwException( Packet response, Throwable t ) { // Use of RETURN is correct -- Fiber processing does not set packet for type of THROW set(RETURN, null, response, t); }