Using the application service
The application service, which implements the com.ibm.hats.runtime.services.IApplicationService
interface, provides methods for retrieving information related to
a ZIETrans rich client application. Each ZIETrans rich client application
plug-in installed and enabled in the Eclipse environment will have
an associated IApplicationService object. The application service
object for an application should be retrieved from the service manager. Sample code to retrieve the application service:
IApplicationService applicationService =
serviceManager.getApplicationService("myPluginId");
The getApplicationService(String) method
will return null if the specified application ID is invalid or the
plug-in failed to start.Table 1 identifies the methods that can be called
by the IApplicationService object.
Method | Description |
---|---|
getApplication() | Returns an Application object which contains information about the application. This object is not guaranteed to be synchronized with the application.hap file, and the use of the object returned by this method should only be used to retrieve information. Do not use this object to alter any settings. |
getApplicationId() | Returns the application identifier. |
getConfig() | Returns the configuration. |
getRuntimeService() | Returns the runtime service. |
getServiceManager() | Returns the service manager that instantiated this service. |