org.rhq.modules.plugins.jbossas7
Class ConfigurationWriteDelegate

java.lang.Object
  extended by org.rhq.modules.plugins.jbossas7.ConfigurationWriteDelegate
All Implemented Interfaces:
ConfigurationFacet

public class ConfigurationWriteDelegate
extends Object
implements ConfigurationFacet


Constructor Summary
ConfigurationWriteDelegate(org.rhq.core.domain.configuration.definition.ConfigurationDefinition configDef, ASConnection connection, Address address)
          Create a new configuration delegate, that reads the attributes for the resource at address.
 
Method Summary
 org.rhq.core.domain.configuration.Configuration loadResourceConfiguration()
          Trigger loading of a configuration by talking to the remote resource.
protected  CompositeOperation updateGenerateOperationFromProperties(org.rhq.core.domain.configuration.Configuration conf, Address address)
           
 void updateResourceConfiguration(ConfigurationUpdateReport report)
          Write the configuration back to the AS.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConfigurationWriteDelegate

public ConfigurationWriteDelegate(org.rhq.core.domain.configuration.definition.ConfigurationDefinition configDef,
                                  ASConnection connection,
                                  Address address)
Create a new configuration delegate, that reads the attributes for the resource at address.

Parameters:
configDef - Configuration definition for the configuration
connection - asConnection to use
address - address of the resource.
Method Detail

loadResourceConfiguration

public org.rhq.core.domain.configuration.Configuration loadResourceConfiguration()
                                                                          throws Exception
Trigger loading of a configuration by talking to the remote resource.

Specified by:
loadResourceConfiguration in interface ConfigurationFacet
Returns:
The initialized configuration
Throws:
Exception - If anything goes wrong.

updateResourceConfiguration

public void updateResourceConfiguration(ConfigurationUpdateReport report)
Write the configuration back to the AS. Care must be taken, not to send properties that are read-only, as AS will choke on them.

Specified by:
updateResourceConfiguration in interface ConfigurationFacet
Parameters:
report - Report containing the new configuration

updateGenerateOperationFromProperties

protected CompositeOperation updateGenerateOperationFromProperties(org.rhq.core.domain.configuration.Configuration conf,
                                                                   Address address)


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.