|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.system.ServiceConfigurator
public class ServiceConfigurator
Service configuration helper.
Constructor Summary | |
---|---|
ServiceConfigurator(javax.management.MBeanServer server,
ServiceController serviceController,
ServiceCreator serviceCreator)
Constructor |
Method Summary | |
---|---|
protected void |
configure(javax.management.ObjectName objectName,
javax.management.ObjectName loaderName,
Element mbeanElement,
List mbeans)
The configure method configures an mbean based on the xml
element configuration passed in. |
String |
getConfiguration(javax.management.ObjectName[] objectNames)
Builds a string that consists of the configuration elements of the currently running MBeans registered in the server. |
static StringBuffer |
getElementContent(Element element)
A utility method that transforms the contents of the argument element into a StringBuffer representation that can be reparsed. |
List |
install(Element config,
javax.management.ObjectName loaderName)
The install method iterates through the mbean tags in the
supplied xml configuration and creates and configures the mbeans shown. |
void |
setServiceBinding(ServiceBinding serviceBinding)
Dynamically plug-in a ServiceBinding policy to possibly override the configuration of a service. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ServiceConfigurator(javax.management.MBeanServer server, ServiceController serviceController, ServiceCreator serviceCreator)
server
- serviceController
- serviceCreator
- Method Detail |
---|
public void setServiceBinding(ServiceBinding serviceBinding)
serviceBinding
- policypublic List install(Element config, javax.management.ObjectName loaderName) throws DeploymentException
install
method iterates through the mbean tags in the
supplied xml configuration and creates and configures the mbeans shown.
The mbean configuration can be nested.
config
- the xml Element
containing the configuration of
the mbeans to create and configure.
List
of ObjectNames of created mbeans.
DeploymentException
- if an error occurspublic String getConfiguration(javax.management.ObjectName[] objectNames) throws Exception
Exception
- Failed to construct configuration.protected void configure(javax.management.ObjectName objectName, javax.management.ObjectName loaderName, Element mbeanElement, List mbeans) throws Exception
configure
method configures an mbean based on the xml
element configuration passed in. Three formats are supported:
<attribute name="(name)">(value)</attribute> <depends
optional-attribute-name="(name)">(object name of mbean
referenced)</depends> <depends-list optional-attribute-name="(name)">
[list of] </depends-list-element>(object name)</depends-list-element>
</depends-list>
The last two can include nested mbean configurations or ObjectNames.
SIDE-EFFECT: adds all mbeans this one depends on to the ServiceContext
structures.
mbeanElement
- an Element
value
Exception
- if an error occurspublic static StringBuffer getElementContent(Element element) throws IOException, TransformerException
element
- - the parent dom element whose contents are to be extracted as an xml document string.
IOException
TransformerException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |