Search in sources :

Example 1 with NextAction

use of org.onebusaway.presentation.model.NextAction in project onebusaway-application-modules by camsys.

the class NextActionSupport method getNextActionOrSuccess.

protected String getNextActionOrSuccess() {
    List<NextAction> stack = getNextActionStack(false);
    if (stack == null || stack.isEmpty())
        return SUCCESS;
    NextAction next = stack.remove(stack.size() - 1);
    Map<String, String[]> params = next.getParameters();
    if (params != null && !params.isEmpty()) {
        ActionContext context = ActionContext.getContext();
        Map<String, Object> contextParameters = context.getParameters();
        contextParameters.putAll(params);
    }
    return next.getAction();
}
Also used : ActionContext(com.opensymphony.xwork2.ActionContext) NextAction(org.onebusaway.presentation.model.NextAction)

Example 2 with NextAction

use of org.onebusaway.presentation.model.NextAction in project onebusaway-application-modules by camsys.

the class NextActionSupport method pushNextAction.

protected void pushNextAction(String action) {
    List<NextAction> stack = getNextActionStack(true);
    stack.add(new NextAction(action));
}
Also used : NextAction(org.onebusaway.presentation.model.NextAction)

Aggregations

NextAction (org.onebusaway.presentation.model.NextAction)2 ActionContext (com.opensymphony.xwork2.ActionContext)1