|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
org.huihoo.jfox.service.ComponentSupport
| Field Summary | |
protected Logger |
logger
|
protected java.lang.String |
name
service name of the service |
protected javax.management.ObjectName |
objectName
the ObjectName of the service register into the MBeanServer |
protected java.lang.Object |
proxyInstance
|
protected long |
sequence
|
protected javax.management.MBeanServer |
server
MBeanService instance |
protected State |
state
the status value of the service |
| Constructor Summary | |
ComponentSupport()
|
|
ComponentSupport(java.lang.String name)
|
|
| Method Summary | |
void |
destroy()
doDestroy the service, tear down |
protected abstract void |
doDestroy()
do actually destory action |
protected abstract void |
doInit()
do actually create action |
Logger |
getLogger()
get the logger |
java.lang.String |
getName()
get the name of the Service, example: NamingService |
javax.management.ObjectName |
getObjectName()
get the ObjectName of the Service, if not registered in MBeanServer, will return null the ObjectName maybe signed in the MLet Config file |
java.lang.reflect.Proxy |
getProxyInstance()
get the proxy instance if return itself, unregisterMBean will invalidate |
State |
getState()
get the state of the Service, the status defined in Status class |
void |
handleNotification(javax.management.Notification notification,
java.lang.Object obj)
|
void |
init()
doCreate the service, do expensive operations etc |
protected static java.lang.String |
parseName(java.lang.String className)
|
void |
postDeregister()
|
void |
postRegister(java.lang.Boolean registrationDone)
|
void |
preDeregister()
|
javax.management.ObjectName |
preRegister(javax.management.MBeanServer server,
javax.management.ObjectName name)
ObjectName must specified in the MLet, or use registerMBean specified explicitly |
protected void |
setLogger(Logger logger)
|
protected void |
setName(java.lang.String name)
|
| Field Detail |
protected java.lang.String name
protected javax.management.ObjectName objectName
protected volatile State state
protected javax.management.MBeanServer server
protected Logger logger
protected volatile long sequence
protected java.lang.Object proxyInstance
| Constructor Detail |
public ComponentSupport()
public ComponentSupport(java.lang.String name)
| Method Detail |
public java.lang.String getName()
ComponentgetName in interface Componentprotected void setName(java.lang.String name)
public javax.management.ObjectName getObjectName()
ComponentSupportMBeangetObjectName in interface ComponentSupportMBeanpublic State getState()
ComponentgetState in interface Componentpublic java.lang.reflect.Proxy getProxyInstance()
getProxyInstance in interface ComponentSupportMBeanpublic Logger getLogger()
LoggablegetLogger in interface Loggableprotected void setLogger(Logger logger)
public void init()
throws java.lang.Exception
Componentinit in interface Component
public void destroy()
throws java.lang.Exception
Componentdestroy in interface Component
public javax.management.ObjectName preRegister(javax.management.MBeanServer server,
javax.management.ObjectName name)
throws java.lang.Exception
public void postRegister(java.lang.Boolean registrationDone)
public void preDeregister()
throws java.lang.Exception
public void postDeregister()
public void handleNotification(javax.management.Notification notification,
java.lang.Object obj)
protected abstract void doInit()
throws java.lang.Exception
protected abstract void doDestroy()
throws java.lang.Exception
protected static java.lang.String parseName(java.lang.String className)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||