hi,

as far as i understand it, the calling sequenze of an action mapping looks
like this:
Interceptor 1-> Interceptor 2->...-> Action-> Result->...-> Interceptor 2->
Interceptor 1
(see http://struts.apache.org/2.0.11.2/docs/big-picture.html)

But what happens when i use this AuthenticationInterceptor:

public class AuthenticationInterceptor extends AbstractInterceptor {

  public String intercept( ActionInvocation actionInvocation ) throws
Exception
  {
    Map session = actionInvocation.getInvocationContext().getSession();
    User user = (User) session.get( Struts2PortfolioConstants.USER );
    if (user == null) {
      return Action.LOGIN;
    }
    else {
      (( UserAwareAction ) actionInvocation.getAction()).setUser(user);
      return actionInvocation.invoke();
    }
  }

}
This is adapted from "Struts 2 in Action" and it looks like here the calling
sequence would be
Interceptor 1-> AuthenticationInterceptor-> Interceptor 1-> Result

So in the normal case the Result is generated within the Interceptors while
the second code suggests that the Result is generated aber the last
Interceptor has returned.
Or is both true?

Regards,
Stephan
-- 
View this message in context: 
http://www.nabble.com/Confused-by-Result-generation-tp20067494p20067494.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to