Package ome.api
Interface StatefulServiceInterface
-
- All Superinterfaces:
ServiceInterface
- All Known Subinterfaces:
JobHandle
,RawFileStore
,RawPixelsStore
,RenderingEngine
,Search
,ThumbnailStore
public interface StatefulServiceInterface extends ServiceInterface
OMERO API Interface with stateful semantics. As of 4.0, each stateful service is responsible for providing its own passivation/activation logic in the similarly named methods.- Since:
- OME3.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
activate()
Completely restore this service for active use from whatever passivation it has implemented.void
close()
signals the end of the service lifecycle.EventContext
getCurrentEventContext()
Returns the currentEventContext
for this instance.void
passivate()
Perform whatever passivation is possible or throw an exception.
-
-
-
Method Detail
-
passivate
void passivate()
Perform whatever passivation is possible or throw an exception. A good passivation method will free up as much memory as possible, most likely by storing it to disk. A call to passivate should be safe even if the service is already passivated.
-
activate
void activate()
Completely restore this service for active use from whatever passivation it has implemented. A call to activate should be safe even if the service is already activated.
-
close
void close()
signals the end of the service lifecycle. Resources such as Sessions can be released. All further calls will throw an exception.
-
getCurrentEventContext
EventContext getCurrentEventContext()
Returns the currentEventContext
for this instance. This is useful for later identifying changes made by thisEvent
.
-
-