|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwt.services.StandardManager
StandardManager is the base class for NetFactor sevices and managers..
Use the newStandardManager
static factory method(s), not
the StandardManager
constructor, to construct instances
of this class. Instances must be constructed using the static factory(s),
in order to ensure proper initialization of the instance.
Supported API: true
Extendable: false
Field Summary | |
private static String |
CLASSNAME
|
private ManagerService |
managerService
|
private int |
managerStatus
|
private String |
name
|
private static String |
RESOURCE
|
private String |
startupType
|
Fields inherited from interface wt.services.Manager |
MANAGER_SERVICE, STARTUP_AUTOMATIC, STARTUP_MANUAL, STATUS_EMERGENCY_SHUTDOWN, STATUS_EMERGENCY_SHUTTING_DOWN, STATUS_SHUTDOWN, STATUS_SHUTDOWN_ERRORS, STATUS_SHUTDOWN_FAILURE, STATUS_SHUTTING_DOWN, STATUS_STARTED, STATUS_STARTED_ERRORS, STATUS_STARTING_UP, STATUS_STARTUP_FAILURE |
Constructor Summary | |
StandardManager()
|
Method Summary | |
void |
emergencyShutdown()
Manager emergency shutdown operation. |
protected void |
emergencyShutdownComplete()
Method for dispatching a Manager startup event to all listeners. |
protected void |
emergencyShuttingDown()
Method for dispatching a Manager emergency shutdown event to all listeners. |
ClassInfo |
getClassInfo()
Returns the ClassInfo object for this class. |
String |
getConceptualClassname()
Deprecated. |
ManagerService |
getManagerService()
Gets the value of the attribute: managerService; Service which manages this manager Supported API: true |
int |
getManagerStatus()
Gets the value of the attribute: managerStatus; Manager status set to Manager.STATUS_SHUTDOWN, Manager.STATUS_STARTED, ... Supported API: true |
String |
getName()
Gets the value of the attribute: name; Manager name Supported API: true |
String |
getStartupType()
Gets the value of the attribute: startupType; Manager startup type. |
protected void |
init(String managerName,
String startupType)
Supported API: false |
protected void |
initialize()
Supported API: false |
protected void |
initialize(String name,
String startupType)
Supports initialization, following construction of an instance. |
boolean |
isStarted()
Determin if the manager is started Answers true if status is STATUS_STARTED or STATUS_STATUS_ERRORS. |
static StandardManager |
newStandardManager()
Supported API: false |
static StandardManager |
newStandardManager(String name,
String startupType)
Supported API: false |
protected void |
performEmergencyShutdownProcess()
Dummy method to be overridden by subclasses. |
protected void |
performShutdownProcess()
Dummy method to be overridden by subclasses. |
protected void |
performStartupProcess()
Dummy method to be overridden by subclasses. |
void |
registerEvents(ManagerService managerService)
Register events with the passed ManagerService. |
void |
setManagerService(ManagerService managerService)
Supported API: false |
void |
shutdown()
Manager shutdown operation. |
protected void |
shutdownFailure()
Method for dispatching a Manager shutdown failure event to all listeners. |
protected void |
shutdownSuccess()
Method for dispatching a Manager startup event to all listeners. |
protected void |
shuttingDown()
Method for dispatching a Manager startup event to all listeners. |
protected void |
started()
Method for dispatching a Manager started event to all listeners. |
protected void |
startedErrors()
Method for dispatching a Manager startup event to all listeners. |
protected void |
startingUp()
Method for dispatching a Manager starting up event to all listeners. |
void |
startup()
Template routine for starting up a service. |
protected void |
startupFailure()
Method for dispatching a Manager startup event to all listeners. |
String |
toString()
Returns the conceptual (modeled) name for the class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
private static final String RESOURCE
private static final String CLASSNAME
private String name
private String startupType
private int managerStatus
private ManagerService managerService
Constructor Detail |
public StandardManager()
Method Detail |
public String getConceptualClassname()
getConceptualClassname
in interface NetFactor
public String toString()
public ClassInfo getClassInfo() throws WTIntrospectionException
getClassInfo
in interface NetFactor
WTIntrospectionException
public String getName()
getName
in interface Manager
public String getStartupType()
Must be either Manager.STARTUP_AUTOMATIC or manager.STARTUP_MANUAL
Supported API: true
getStartupType
in interface Manager
wt.services.Manager.STARTUP_AUTOMATIC
public int getManagerStatus()
getManagerStatus
in interface Manager
Manager.STATUS_SHUTDOWN
public ManagerService getManagerService()
getManagerService
in interface Manager
public static StandardManager newStandardManager() throws WTException
WTException
public static StandardManager newStandardManager(String name, String startupType) throws WTException
name
- startupType
-
WTException
protected void initialize(String name, String startupType) throws WTException
name
- startupType
-
WTException
protected void init(String managerName, String startupType)
managerName
- startupType
- protected void initialize() throws WTException
WTException
protected void performStartupProcess() throws ManagerException
ManagerException
protected void performShutdownProcess() throws ManagerException
ManagerException
protected void performEmergencyShutdownProcess()
protected void startingUp() throws ManagerException
ManagerException
protected void started()
protected void startedErrors()
protected void startupFailure()
protected void shuttingDown() throws ManagerException
ManagerException
protected void shutdownSuccess()
protected void shutdownFailure()
protected void emergencyShuttingDown()
protected void emergencyShutdownComplete()
public void startup() throws ManagerException
This is a template method and should generally not be overridden. Typically the method performStartupProcess sshould be overridden by subclasses.
Manager startup operation. Generally this operation changes the manager status from:
STATUS_SHUTDOWN -> STATUS_STARTING -> STATUS_STARTED.
Supported API: false
startup
in interface Manager
ManagerException
public void shutdown() throws ManagerException
Generally this operation changes the manager status from:
STATUS_STARTED -> STATUS_SHUTTING_DOWN -> STATUS_SHUTDOWN
Template routine for shutting down a service. This method calls the shuttingDown method which handles generating and synchronously dispatching an event to all listeners. Listeners may object to the shutdown by throwing a ManagerException.
This is a template method and should generally not be overridden.
Typically the method performShutdownProcess should be overridden
by subclasses.
Supported API: false
shutdown
in interface Manager
ManagerException
public void emergencyShutdown() throws ManagerException
Template routine for emergency shutdown of a manager. This method calls the emergencyShuttingDown method which handles generating and synchronously dispatching an event to all listeners. Listeners may not object to this operation.
This is a template method and should generally not be overridden.
Typically the method performEmergencyShutdownProcess should be overridden
by subclasses.
Supported API: false
emergencyShutdown
in interface Manager
ManagerException
public boolean isStarted()
isStarted
in interface Manager
public void registerEvents(ManagerService managerService)
registerEvents
in interface Manager
managerService
- the ManagerService with which to register events.public void setManagerService(ManagerService managerService)
setManagerService
in interface Manager
managerService
-
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |