com.sun.enterprise.module
Interface LifecyclePolicy


@Contract
public interface LifecyclePolicy

Modules that wish to invoke special logic when it is loaded, started or stopped should implement this interface.

To define an implementation of this in a module, write a class that implements this interface and puts Service on it. Maven will take care of the rest.

Author:
dochez
See Also:
ManifestConstants.LIFECYLE_POLICY

Method Summary
 void start(Module module)
          Callback when the module enters the READY state.
 void stop(Module module)
          Callback before the module starts being unloaded.
 

Method Detail

start

void start(Module module)
Callback when the module enters the READY state. This is a good time to do any type of one time initialization or set up access to resources

Parameters:
module - the module instance

stop

void stop(Module module)
Callback before the module starts being unloaded. The runtime will free all the module resources and returned to a NEW state.

Parameters:
module - the module instance


Copyright © 2013 Oracle Corporation. All Rights Reserved.