Package omero.api
Interface _ServiceFactoryOperationsNC
-
- All Superinterfaces:
Glacier2._SessionOperationsNC
,_SessionOperationsNC
- All Known Subinterfaces:
ServiceFactory
- All Known Implementing Classes:
_ServiceFactoryDisp
,_ServiceFactoryTie
public interface _ServiceFactoryOperationsNC extends _SessionOperationsNC
Starting point for all OMERO.blitz interaction.A ServiceFactory once acquired can be used to create any number of service proxies to the server. Most services implement
ServiceInterface
or its subinterfaceStatefulServiceInterface
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.List<java.lang.String>
activeServices()
Returns a list of string ids for currently active services.void
closeOnDestroy()
Marks the session for closure rather than detachment, which will be triggered by the destruction of the Glacier2 connection via router.destroySession() Closing the session rather the detaching is more secure, since all resources are removed from the server and can safely be set once it is clear that a client is finished with those resources.StatefulServiceInterfacePrx
createByName(java.lang.String name)
Allows looking up any stateful service by name.ExporterPrx
createExporter()
JobHandlePrx
createJobHandle()
RawFileStorePrx
createRawFileStore()
RawPixelsStorePrx
createRawPixelsStore()
RenderingEnginePrx
createRenderingEngine()
SearchPrx
createSearchService()
ThumbnailStorePrx
createThumbnailStore()
void
detachOnDestroy()
Marks the session for detachment rather than closure, which will be triggered by the destruction of the Glacier2 connection via router.destroySession() This is the default and allows a lost session to be reconnected, at a slight security cost since the session will persist longer and can be used by others if the UUID is intercepted.IAdminPrx
getAdminService()
ServiceInterfacePrx
getByName(java.lang.String name)
Allows looking up any stateless service by name.IConfigPrx
getConfigService()
IContainerPrx
getContainerService()
ILdapPrx
getLdapService()
IMetadataPrx
getMetadataService()
IPixelsPrx
getPixelsService()
IProjectionPrx
getProjectionService()
IQueryPrx
getQueryService()
IRenderingSettingsPrx
getRenderingSettingsService()
IRepositoryInfoPrx
getRepositoryInfoService()
IRoiPrx
getRoiService()
IScriptPrx
getScriptService()
java.util.List<IObject>
getSecurityContexts()
Provides a list of all valid security contexts for this session.ISessionPrx
getSessionService()
ISharePrx
getShareService()
ITimelinePrx
getTimelineService()
ITypesPrx
getTypesService()
IUpdatePrx
getUpdateService()
boolean
keepAlive(ServiceInterfacePrx proxy)
Returns true if the given service is alive.long
keepAllAlive(ServiceInterfacePrx[] proxies)
Requests that the given services be marked as alive.void
setCallback(ClientCallbackPrx callback)
Sets the single callback used by the ServiceFactory to communicate with the client application.IObject
setSecurityContext(IObject obj)
Changes the security context for the current session.void
setSecurityPassword(java.lang.String password)
Re-validates the password for the current session.SharedResourcesPrx
sharedResources()
Returns a reference to a back-end manager.void
subscribe(java.lang.String topicName, Ice.ObjectPrx prx)
Subscribe to a given topic.-
Methods inherited from interface omero.cmd._SessionOperationsNC
submit_async
-
-
-
-
Method Detail
-
getSecurityContexts
java.util.List<IObject> getSecurityContexts() throws ServerError
Provides a list of all valid security contexts for this session. Each of the returnedIObject
instances can be passed tosetSecurityContext
.- Throws:
ServerError
-
setSecurityContext
IObject setSecurityContext(IObject obj) throws ServerError
Changes the security context for the current session.A security context limits the set of objects which will be returned by all queries and restricts what updates can be made.
Current valid values for security context:
ExperimenterGroup
- logs into a specific groupShare
- uses IShare to activate a share
Passing an unloaded version of either object type will change the way the current session operates. Note: only objects which are returned by the
getSecurityContext
method are considered valid. Any other instance will cause an exception to be thrown.Example usage in Python:
sf = client.createSession() objs = sf.getSecurityContexts() old = sf.setSecurityContext(objs\[-1])
- Throws:
ServerError
-
setSecurityPassword
void setSecurityPassword(java.lang.String password) throws ServerError
Re-validates the password for the current session. This prevents See methods that mention "HasPassword".- Throws:
ServerError
-
getAdminService
IAdminPrx getAdminService() throws ServerError
- Throws:
ServerError
-
getConfigService
IConfigPrx getConfigService() throws ServerError
- Throws:
ServerError
-
getContainerService
IContainerPrx getContainerService() throws ServerError
- Throws:
ServerError
-
getLdapService
ILdapPrx getLdapService() throws ServerError
- Throws:
ServerError
-
getPixelsService
IPixelsPrx getPixelsService() throws ServerError
- Throws:
ServerError
-
getProjectionService
IProjectionPrx getProjectionService() throws ServerError
- Throws:
ServerError
-
getQueryService
IQueryPrx getQueryService() throws ServerError
- Throws:
ServerError
-
getRenderingSettingsService
IRenderingSettingsPrx getRenderingSettingsService() throws ServerError
- Throws:
ServerError
-
getRepositoryInfoService
IRepositoryInfoPrx getRepositoryInfoService() throws ServerError
- Throws:
ServerError
-
getRoiService
IRoiPrx getRoiService() throws ServerError
- Throws:
ServerError
-
getScriptService
IScriptPrx getScriptService() throws ServerError
- Throws:
ServerError
-
getSessionService
ISessionPrx getSessionService() throws ServerError
- Throws:
ServerError
-
getShareService
ISharePrx getShareService() throws ServerError
- Throws:
ServerError
-
getTimelineService
ITimelinePrx getTimelineService() throws ServerError
- Throws:
ServerError
-
getTypesService
ITypesPrx getTypesService() throws ServerError
- Throws:
ServerError
-
getUpdateService
IUpdatePrx getUpdateService() throws ServerError
- Throws:
ServerError
-
getMetadataService
IMetadataPrx getMetadataService() throws ServerError
- Throws:
ServerError
-
createExporter
ExporterPrx createExporter() throws ServerError
- Throws:
ServerError
-
createJobHandle
JobHandlePrx createJobHandle() throws ServerError
- Throws:
ServerError
-
createRawFileStore
RawFileStorePrx createRawFileStore() throws ServerError
- Throws:
ServerError
-
createRawPixelsStore
RawPixelsStorePrx createRawPixelsStore() throws ServerError
- Throws:
ServerError
-
createRenderingEngine
RenderingEnginePrx createRenderingEngine() throws ServerError
- Throws:
ServerError
-
createSearchService
SearchPrx createSearchService() throws ServerError
- Throws:
ServerError
-
createThumbnailStore
ThumbnailStorePrx createThumbnailStore() throws ServerError
- Throws:
ServerError
-
sharedResources
SharedResourcesPrx sharedResources() throws ServerError
Returns a reference to a back-end manager. TheSharedResources
service provides look ups for various facilities offered by OMERO: These facilities may or may not be available on first request.- Throws:
ServerError
- See Also:
SharedResources
-
getByName
ServiceInterfacePrx getByName(java.lang.String name) throws ServerError
Allows looking up any stateless service by name. See Constants.ice for examples of services. If a service has been added by third-parties, getByName can be used even though no concrete method is available.- Throws:
ServerError
-
createByName
StatefulServiceInterfacePrx createByName(java.lang.String name) throws ServerError
Allows looking up any stateful service by name. See Constants.ice for examples of services. If a service has been added by third-parties, createByName can be used even though no concrete method is available.- Throws:
ServerError
-
subscribe
void subscribe(java.lang.String topicName, Ice.ObjectPrx prx) throws ServerError
Subscribe to a given topic. The topic must exist and the user must have sufficient permissions for that topic. Further the proxy object must match the required type for the topic as encoded in the topic name.- Throws:
ServerError
-
setCallback
void setCallback(ClientCallbackPrx callback) throws ServerError
Sets the single callback used by the ServiceFactory to communicate with the client application. A default callback is set by the omero::client object on session creation which should suffice for most usage. See the client object's documentation in each language mapping for ways to use the callback.- Throws:
ServerError
-
closeOnDestroy
void closeOnDestroy() throws ServerError
Marks the session for closure rather than detachment, which will be triggered by the destruction of the Glacier2 connection via router.destroySession() Closing the session rather the detaching is more secure, since all resources are removed from the server and can safely be set once it is clear that a client is finished with those resources.- Throws:
ServerError
-
detachOnDestroy
void detachOnDestroy() throws ServerError
Marks the session for detachment rather than closure, which will be triggered by the destruction of the Glacier2 connection via router.destroySession() This is the default and allows a lost session to be reconnected, at a slight security cost since the session will persist longer and can be used by others if the UUID is intercepted.- Throws:
ServerError
-
activeServices
java.util.List<java.lang.String> activeServices() throws ServerError
Returns a list of string ids for currently active services. This will _not_ keep services alive, and in fact checks for all expired services and removes them.- Throws:
ServerError
-
keepAllAlive
long keepAllAlive(ServiceInterfacePrx[] proxies) throws ServerError
Requests that the given services be marked as alive. It is possible that one of the services has already timed out, in which case the returned long value will be non-zero. Specifically, the bit representing the 0-based index will be 1:if (retval & 1<<idx == 1<<idx) { // not alive }
Except for fatal server or session errors, this method should never throw an exception.- Throws:
ServerError
-
keepAlive
boolean keepAlive(ServiceInterfacePrx proxy) throws ServerError
Returns true if the given service is alive. Except for fatal server or session errors, this method should never throw an exception.- Throws:
ServerError
-
-