Package org.atmosphere.cpr
Interface AtmosphereResourceSessionFactory
-
- All Known Implementing Classes:
DefaultAtmosphereResourceSessionFactory
public interface AtmosphereResourceSessionFactoryFactory forAtmosphereResourceSessioninstances- Author:
- uklance (https://github.com/uklance)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voiddestroy()AtmosphereResourceSessiongetSession(AtmosphereResource resource)Returns the current session associated with theAtmosphereResource, or creates one if it does not yet exist.AtmosphereResourceSessiongetSession(AtmosphereResource resource, boolean create)Returns the current session associated with theAtmosphereResourceor, if there is no current session and create is true, returns a new session.
-
-
-
Method Detail
-
getSession
AtmosphereResourceSession getSession(AtmosphereResource resource, boolean create)
Returns the current session associated with theAtmosphereResourceor, if there is no current session and create is true, returns a new session. If create is false and the request has no valid HttpSession, this method returns null.- Parameters:
resource- AnAtmosphereResourcecreate- true to create a new session if necessary; false to return null if there's no current session- Returns:
- the session associated with this request or null if create is false and the resource has no valid session
-
getSession
AtmosphereResourceSession getSession(AtmosphereResource resource)
Returns the current session associated with theAtmosphereResource, or creates one if it does not yet exist.- Parameters:
resource- AnAtmosphereResource- Returns:
- the current session associated with the
AtmosphereResource, or creates one if it does not yet exist.
-
destroy
void destroy()
-
-