|
Foundation |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ServiceInterface
Interface used to designate a service that is only available within the local JVM.
While this interface extends
com.sas.services.RemoteServiceInterface
, note that this interface
does not throw RemoteException
, thereby facilitating a
service interface that may be used locally within a JVM process.
Field Summary |
---|
Fields inherited from interface com.sas.services.RemoteServiceInterface |
---|
CLASS_IDENTIFIER, CLASS_IDENTIFIER_1_1, CLASS_IDENTIFIER_1_2, CLASS_IDENTIFIER_SERVICE_TYPE, CLASS_IDENTIFIER_SERVICE_TYPE_1_1, CLASS_IDENTIFIER_SERVICE_TYPE_1_2 |
Method Summary | |
---|---|
void |
configure(ServiceConfigurationInterface serviceConfiguration)
Configures the service. |
void |
destroy()
Destroys the service. |
long |
getCreationTime()
Gets the time at which this configuration was created. |
ServiceConfigurationInterface |
getServiceConfiguration()
Gets the service's configuration. |
RemoteServiceInterface |
getServiceProxy()
Gets the service proxy. |
short |
getServiceState()
Gets the current state of the service. |
boolean |
isAccessibleToRemoteClients()
Determines whether or not the service is accessible to remote clients. |
boolean |
isExported()
Determines whether or not the service has been exported to the RMI system. |
void |
setServiceState(ServiceState serviceState)
Sets the state of the service. |
Methods inherited from interface com.sas.services.RemoteServiceInterface |
---|
getServiceConfiguration, reconfigure |
Methods inherited from interface com.sas.services.mgmt.ServiceNotificationBroadcasterInterface |
---|
addServiceObserver, notifyServiceObservers, removeAllServiceObservers, removeServiceObserver |
Method Detail |
---|
void destroy() throws ServiceException
The service should release any resources it holds in preparation for termination of use of this service.
destroy
in interface RemoteServiceInterface
ServiceException
- if the service is unable to prepare itself
for destruction.ServiceConfigurationInterface getServiceConfiguration()
getServiceConfiguration
in interface RemoteServiceInterface
null
if no service
configuration is defined.void configure(ServiceConfigurationInterface serviceConfiguration) throws InitializationException, ServiceException
An InitializationException
will be thrown if the service
is unable to complete the configuration request successfully.
Suggested policy for handling such an exception is for the service to
invoke its destroy() method if a service is being initialized.
A ServiceException
will be thrown if a request to
reconfigure the service fails and the service is able to restore its
previous configuration. If a reconfiguration request fails and the
service is unable to restore its previous configuration, then an
InitializationException
should be thrown instead of a
ServiceException
.
configure
in interface RemoteServiceInterface
serviceConfiguration
- An object containing configuration data
necessary to initialize or re-configure a service. Note that the
service must verify that the object type is supported.
An InitializationException
should be thrown if
the initialization was not completed successfully to indicate that
the instance should not be used.
InitializationException
- if unable to initialize the service.
If this exception is thrown then the
service should not be used.
ServiceException
- if a previously initialized service
does not support reconfiguration.long getCreationTime()
getCreationTime
in interface RemoteServiceInterface
short getServiceState()
getServiceState
in interface RemoteServiceInterface
boolean isAccessibleToRemoteClients() throws ServiceException
isAccessibleToRemoteClients
in interface RemoteServiceInterface
true
if the service is intended to be accessible
to remote clients or
false
if it isn't.
ServiceException
- if unable to process the request.boolean isExported() throws ServiceException
isExported
in interface RemoteServiceInterface
true
if the service has been exported or
false
if it hasn't.
ServiceException
- if unable to process the request.void setServiceState(ServiceState serviceState) throws ServiceException
setServiceState
in interface RemoteServiceInterface
serviceState
- Service's state.
ServiceException
- if an invalid service state is specified.RemoteServiceInterface getServiceProxy()
getServiceProxy
in interface RemoteServiceInterface
null
if a proxy is not available.
|
Foundation |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |