public interface Service
The lifecycle for a service starts with the init
method when the service starts.
myService.init(config);
...
myService.hello();
...
myService.hello();
...
myService.destroy();
Modifier and Type | Method and Description |
---|---|
void |
destroy()
Cleanup the service instance.
|
void |
init(ServletConfig config)
Initialize the service instance.
|
void init(ServletConfig config) throws ServletException
config
- the configuration for the service.ServletException
void destroy()