Example usage for org.apache.shiro.subject SubjectContext getSessionId

List of usage examples for org.apache.shiro.subject SubjectContext getSessionId

Introduction

In this page you can find the example usage for org.apache.shiro.subject SubjectContext getSessionId.

Prototype

Serializable getSessionId();

Source Link

Document

Returns the session id of the session that should be associated with the constructed Subject instance.

Usage

From source file:com.caricah.iotracah.bootstrap.security.IOTSecurityManager.java

License:Apache License

protected IOTClient resolveContextSession(SubjectContext context) throws InvalidSessionException {

    Serializable sessionId = context.getSessionId();

    if (sessionId != null) {
        SessionKey key = new DefaultSessionKey(sessionId);
        return (IOTClient) getSession(key);
    }//from   w w w. j  a v a  2s.  c  om

    return null;

}