- All Superinterfaces:
Object
Administers the services of an IceBox server.
Remarks:
The Slice compiler generated this skeleton interface from Slice interface ::IceBox::ServiceManager.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.zeroc.Ice.Object
Object.Ice_invokeResult -
Method Summary
Modifier and TypeMethodDescriptionvoidaddObserver(ServiceObserverPrx observer, Current current) Registers a new observer with this service manager.default CompletionStage<OutgoingResponse>dispatch(IncomingRequest request) Dispatches an incoming request to one of the methods of this generated interface, based on the operation name carried by the request.static StringGets the type ID of the associated Slice interface.booleanisServiceRunning(String service, Current current) Returns whether a service is running.voidShuts down all services.voidstartService(String service, Current current) Starts a service.voidstopService(String service, Current current) Stops a service.
-
Method Details
-
startService
void startService(String service, Current current) throws AlreadyStartedException, NoSuchServiceException Starts a service.- Parameters:
service- The service name.current- the Current object of the incoming request- Throws:
AlreadyStartedException- Thrown when the service is already running.NoSuchServiceException- Thrown when IceBox does not know a service namedservice.
-
stopService
void stopService(String service, Current current) throws AlreadyStoppedException, NoSuchServiceException Stops a service.- Parameters:
service- The service name.current- the Current object of the incoming request- Throws:
AlreadyStoppedException- Thrown when the service is already stopped.NoSuchServiceException- Thrown when IceBox does not know a service namedservice.
-
isServiceRunning
Returns whether a service is running.- Parameters:
service- The name of the service to check.current- the Current object of the incoming request- Returns:
trueif the service was started and not stopped; otherwisefalse.- Throws:
NoSuchServiceException- Thrown when IceBox does not know a service namedservice.
-
addObserver
Registers a new observer with this service manager.- Parameters:
observer- The new observer.current- the Current object of the incoming request
-
shutdown
Shuts down all services.- Parameters:
current- the Current object of the incoming request
-
ice_staticId
Gets the type ID of the associated Slice interface.- Returns:
- the string "::IceBox::ServiceManager"
-
dispatch
Dispatches an incoming request to one of the methods of this generated interface, based on the operation name carried by the request.- Specified by:
dispatchin interfaceObject- Parameters:
request- the incoming request- Returns:
- the outgoing response
- Throws:
UserException- if aUserExceptionis thrown, Ice will marshal it as the response payload.
-