Search in sources :

Example 1 with AgiRequest

use of org.asteriskjava.fastagi.AgiRequest in project onebusaway-application-modules by camsys.

the class IntegrationTestingInterceptor method intercept.

@Override
public String intercept(ActionInvocation invocation) throws Exception {
    ActionContext context = invocation.getInvocationContext();
    AgiRequest request = AgiEntryPoint.getAgiRequest(context);
    Map<?, ?> r = request.getRequest();
    /**
     * This interceptor will be called multiple times in the course of
     * processing the actions for a call, so we only check the reset user param
     * once
     */
    Object value = r.remove(RESET_USER);
    if (value != null && value.equals("true"))
        context.getParameters().put(PhoneNumberLoginInterceptor.RESET_USER, Boolean.TRUE);
    return invocation.invoke();
}
Also used : ActionContext(com.opensymphony.xwork2.ActionContext) AgiRequest(org.asteriskjava.fastagi.AgiRequest)

Aggregations

ActionContext (com.opensymphony.xwork2.ActionContext)1 AgiRequest (org.asteriskjava.fastagi.AgiRequest)1