Class DefaultServerEventContextManager
- java.lang.Object
-
- org.silverpeas.core.notification.sse.DefaultServerEventContextManager
-
- All Implemented Interfaces:
SilverpeasServerEventContextManager
@Service @Singleton public class DefaultServerEventContextManager extends Object implements SilverpeasServerEventContextManager
-
-
Constructor Summary
Constructors Constructor Description DefaultServerEventContextManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
cleanContexts()
List<SilverpeasServerEventContext>
getContextSnapshot()
Gets safely a snapshot of the current registered asynchronous contexts.void
register(SilverpeasServerEventContext context)
Register safely the givenSilverpeasServerEventContext
instance.void
unregister(SilverpeasServerEventContext context)
Unregister safely the givenSilverpeasServerEventContext
instance.
-
-
-
Method Detail
-
cleanContexts
@PreDestroy protected void cleanContexts()
-
register
public void register(SilverpeasServerEventContext context)
Description copied from interface:SilverpeasServerEventContextManager
Register safely the givenSilverpeasServerEventContext
instance.- Specified by:
register
in interfaceSilverpeasServerEventContextManager
- Parameters:
context
- theSilverpeasServerEventContext
instance to register.
-
unregister
public void unregister(SilverpeasServerEventContext context)
Description copied from interface:SilverpeasServerEventContextManager
Unregister safely the givenSilverpeasServerEventContext
instance.- Specified by:
unregister
in interfaceSilverpeasServerEventContextManager
- Parameters:
context
- theSilverpeasServerEventContext
instance to unregister.
-
getContextSnapshot
public List<SilverpeasServerEventContext> getContextSnapshot()
Description copied from interface:SilverpeasServerEventContextManager
Gets safely a snapshot of the current registered asynchronous contexts.- Specified by:
getContextSnapshot
in interfaceSilverpeasServerEventContextManager
- Returns:
- a list of
SilverpeasServerEventContext
instances.
-
-