Class DecoratedSession<C>
java.lang.Object
org.wildfly.clustering.session.cache.DecoratedSession<C>
- Type Parameters:
C- the session context type
- All Implemented Interfaces:
AutoCloseable,Supplier<Session<C>>,ImmutableSession,Session<C>
- Direct Known Subclasses:
AttachedSession,CachedSession,ManagedSession
A generic decorated session.
- Author:
- Paul Ferraro
-
Constructor Summary
ConstructorsConstructorDescriptionDecoratedSession(Supplier<Session<C>> reference) DecoratedSession(Session<C> session) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()booleanget()Returns this session's attributes.Returns the local context of this session.getId()Specifies this session's unique identifier.Returns this session's meta data.inthashCode()voidInvalidates this session.booleanisValid()Indicates whether or not this session is valid.toString()
-
Constructor Details
-
DecoratedSession
-
DecoratedSession
-
-
Method Details
-
get
-
getId
Description copied from interface:ImmutableSessionSpecifies this session's unique identifier.- Specified by:
getIdin interfaceImmutableSession- Returns:
- a unique identifier for this session.
-
getContext
Description copied from interface:SessionReturns the local context of this session. The local context is *not* replicated to other nodes in the cluster.- Specified by:
getContextin interfaceSession<C>- Returns:
- a local context
-
getMetaData
Description copied from interface:ImmutableSessionReturns this session's meta data.- Specified by:
getMetaDatain interfaceImmutableSession- Specified by:
getMetaDatain interfaceSession<C>- Returns:
- this session's meta data
-
getAttributes
Description copied from interface:ImmutableSessionReturns this session's attributes.- Specified by:
getAttributesin interfaceImmutableSession- Returns:
- this session's attributes
-
isValid
public boolean isValid()Description copied from interface:ImmutableSessionIndicates whether or not this session is valid.- Specified by:
isValidin interfaceImmutableSession- Returns:
- true, if this session is valid, false otherwise
-
invalidate
public void invalidate()Description copied from interface:SessionInvalidates this session.- Specified by:
invalidatein interfaceSession<C>
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceSession<C>
-
hashCode
-
equals
-
toString
-