public void handleError(Exception cause) throws Exception { payload.setErrorHandled(true); if (!payload.isHandleErrorCauseException()) { payload.setHandledErrorSuccessfully(true); } else { throw new Exception(); } }
public void execute() throws Exception { payload.setExecuted(true); if (!payload.isExecuteCauseException()) { payload.setExecutedSuccessfully(true); } else { throw new Exception(); } }