Package org.beangle.security.web.session.model

Examples of org.beangle.security.web.session.model.SessioninfoBean


    return SessioninfoBean.class;
  }

  public Sessioninfo build(Authentication auth, String serverName, String sessionid) {
    CategoryPrincipal principal = (CategoryPrincipal) auth.getPrincipal();
    SessioninfoBean info = new SessioninfoBean(sessionid, serverName, auth.getName(),
        principal.getFullname());
    info.setCategory(principal.getCategory());
    Object details = auth.getDetails();
    if (details instanceof WebAuthenticationDetails) {
      WebAuthenticationDetails webdetails = (WebAuthenticationDetails) details;
      info.setAgent(webdetails.getAgent().getBrowser().toString());
      info.setOs(webdetails.getAgent().getOs().toString());
      info.setIp(webdetails.getAgent().getIp());
    }
    return info;
  }
View Full Code Here

TOP

Related Classes of org.beangle.security.web.session.model.SessioninfoBean

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.