Package com.opensymphony.xwork

Examples of com.opensymphony.xwork.Action


    }else{
      if(userManager.hasUser(user) == false){
        session.clear();
      }
    }
    Action action = (Action)actionInvocation.getAction();
    if(user != null && (action instanceof LoggedInUserAware)){
      ((LoggedInUserAware)action).setLoggedInUser(user);     
    }       
    return actionInvocation.invoke();
  }
View Full Code Here


    Map session = actionInvocation.getInvocationContext().getSession();
    User user = (User)session.get(SessionConstants.LOGGED_IN_USER);
    if(user == null){
      return Action.LOGIN;
    }else{
      Action action = (Action)actionInvocation.getAction();
      if(action instanceof LoggedInUserAware){
        ((LoggedInUserAware)action).setLoggedInUser(user);
      }
      return actionInvocation.invoke();
    }
View Full Code Here

      if(user != null){
        session.remove(SessionConstants.LOGGED_IN_USER);
      }
      return Action.LOGIN;
    }else
      Action action = (Action)actionInvocation.getAction();
      if(action instanceof LoggedInUserAware){
        ((LoggedInUserAware)action).setLoggedInUser(user);
      }
      return actionInvocation.invoke();
    }
View Full Code Here

  public void init() {
    // no code   
  }

  public String intercept(ActionInvocation actionInvocation) throws Exception {
    Action action = (Action)actionInvocation.getAction();
    if(action instanceof GnizrConfigurationAware){
      ((GnizrConfigurationAware)action).setGnizrConfiguration(gnizrConfiguration);
    }
    return actionInvocation.invoke();
  }
View Full Code Here

*/
public class UserPrefsInterceptor extends AroundInterceptor {
    public static final String USER_PREFS_SESSION_KEY = "_USER_PREFS_SESSION_KEY_";

    protected void before(ActionInvocation invocation) {
        Action action = invocation.getAction();
        if (action instanceof UserPrefsAware) {
            UserPrefs userPrefs = (UserPrefs) invocation.getInvocationContext().getSession().get(USER_PREFS_SESSION_KEY);
            if (userPrefs == null) {
                UserPrefsService service = (UserPrefsService) Application.getInstance().getContainer().getComponent(UserPrefsService.class);
                userPrefs = service.loadUserPrefs(RemoteUser.get().getName());
View Full Code Here

TOP

Related Classes of com.opensymphony.xwork.Action

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.