Class CompositeSessionFactory<C,MV extends Contextual<L>,AV,L>
- java.lang.Object
-
- org.wildfly.clustering.web.cache.session.CompositeImmutableSessionFactory<MV,AV>
-
- org.wildfly.clustering.web.cache.session.CompositeSessionFactory<C,MV,AV,L>
-
- Type Parameters:
C- the ServletContext specification typeV- the session attribute value typeL- the local context type
- All Implemented Interfaces:
AutoCloseable,Creator<String,Map.Entry<MV,AV>,Duration>,Locator<String,Map.Entry<MV,AV>>,Remover<String>,ImmutableSessionFactory<MV,AV>,SessionFactory<C,MV,AV,L>
public class CompositeSessionFactory<C,MV extends Contextual<L>,AV,L> extends CompositeImmutableSessionFactory<MV,AV> implements SessionFactory<C,MV,AV,L>
- Author:
- Paul Ferraro
-
-
Constructor Summary
Constructors Constructor Description CompositeSessionFactory(SessionMetaDataFactory<MV> metaDataFactory, SessionAttributesFactory<C,AV> attributesFactory, Supplier<L> localContextFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()ImmutableSessioncreateImmutableSession(String id, ImmutableSessionMetaData metaData, ImmutableSessionAttributes attributes)Session<L>createSession(String id, Map.Entry<MV,AV> entry, C context)Map.Entry<MV,AV>createValue(String id, Duration defaultTimeout)Map.Entry<MV,AV>findValue(String id)SessionAttributesFactory<C,AV>getAttributesFactory()SessionMetaDataFactory<MV>getMetaDataFactory()booleanpurge(String id)booleanremove(String id)Map.Entry<MV,AV>tryValue(String id)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.wildfly.clustering.web.cache.session.ImmutableSessionFactory
createImmutableSession
-
-
-
-
Constructor Detail
-
CompositeSessionFactory
public CompositeSessionFactory(SessionMetaDataFactory<MV> metaDataFactory, SessionAttributesFactory<C,AV> attributesFactory, Supplier<L> localContextFactory)
-
-
Method Detail
-
createValue
public Map.Entry<MV,AV> createValue(String id, Duration defaultTimeout)
- Specified by:
createValuein interfaceCreator<C,MV extends Contextual<L>,AV>
-
findValue
public Map.Entry<MV,AV> findValue(String id)
- Specified by:
findValuein interfaceLocator<C,MV extends Contextual<L>>- Overrides:
findValuein classCompositeImmutableSessionFactory<MV extends Contextual<L>,AV>
-
tryValue
public Map.Entry<MV,AV> tryValue(String id)
- Specified by:
tryValuein interfaceLocator<C,MV extends Contextual<L>>- Overrides:
tryValuein classCompositeImmutableSessionFactory<MV extends Contextual<L>,AV>
-
getMetaDataFactory
public SessionMetaDataFactory<MV> getMetaDataFactory()
- Specified by:
getMetaDataFactoryin interfaceImmutableSessionFactory<C,MV extends Contextual<L>>- Specified by:
getMetaDataFactoryin interfaceSessionFactory<C,MV extends Contextual<L>,AV,L>- Overrides:
getMetaDataFactoryin classCompositeImmutableSessionFactory<MV extends Contextual<L>,AV>
-
getAttributesFactory
public SessionAttributesFactory<C,AV> getAttributesFactory()
- Specified by:
getAttributesFactoryin interfaceImmutableSessionFactory<C,MV extends Contextual<L>>- Specified by:
getAttributesFactoryin interfaceSessionFactory<C,MV extends Contextual<L>,AV,L>- Overrides:
getAttributesFactoryin classCompositeImmutableSessionFactory<MV extends Contextual<L>,AV>
-
createSession
public Session<L> createSession(String id, Map.Entry<MV,AV> entry, C context)
- Specified by:
createSessionin interfaceSessionFactory<C,MV extends Contextual<L>,AV,L>
-
createImmutableSession
public ImmutableSession createImmutableSession(String id, ImmutableSessionMetaData metaData, ImmutableSessionAttributes attributes)
- Specified by:
createImmutableSessionin interfaceImmutableSessionFactory<C,MV extends Contextual<L>>- Overrides:
createImmutableSessionin classCompositeImmutableSessionFactory<MV extends Contextual<L>,AV>
-
close
public void close()
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceSessionFactory<C,MV extends Contextual<L>,AV,L>
-
-