org.rhq.plugins.jbossas.util
Interface XMLConfigurationEditor

All Known Implementing Classes:
JBossMessagingConfigurationEditor, JMSConfigurationEditor

public interface XMLConfigurationEditor

Author:
Mark Spritzer

Field Summary
static String CONNECTION_MBEAN_NAME
           
static String DATASOURCE_MBEAN_NAME
           
static String DATASOURCE_ROOT_ELEMENT
           
static String JMQ_QUEUE_CODE
           
static String JMQ_TOPIC_CODE
           
static String JMS_ROOT_ELEMENT
           
static int LIST_ATTRIBUTE
           
static int LIST_DEFAULT
           
static int LIST_SUBTAG
           
static String LOCAL_TX_TYPE
           
static int MAP_ATTRIBUTE
           
static int MAP_DEFAULT
           
static int MAP_SUBTAG
           
static String NO_TX_TYPE
           
static int SIMPLE_ATTRIBUTE
           
static int SIMPLE_DEFAULT
           
static int SIMPLE_SUBTAG
           
static String XA_TX_TYPE
           
 
Method Summary
 void deleteComponent(File deploymentFile, String name)
          This method will delete a configuration for a component from an xml file.
 org.rhq.core.domain.configuration.Configuration loadConfiguration(File file, String name)
          This method loads an XML file and converts it into a @see Configuration object
 void updateConfiguration(File deploymentFile, String name, ConfigurationUpdateReport report)
          This method will save a Configuration object into the xml file supplied where the component already existing.
 void updateConfiguration(File deploymentFile, String name, CreateResourceReport report)
          This method will save a Configuration object into the xml file supplied where the component does not already existing.
 

Field Detail

DATASOURCE_ROOT_ELEMENT

static final String DATASOURCE_ROOT_ELEMENT
See Also:
Constant Field Values

JMS_ROOT_ELEMENT

static final String JMS_ROOT_ELEMENT
See Also:
Constant Field Values

DATASOURCE_MBEAN_NAME

static final String DATASOURCE_MBEAN_NAME
See Also:
Constant Field Values

CONNECTION_MBEAN_NAME

static final String CONNECTION_MBEAN_NAME
See Also:
Constant Field Values

NO_TX_TYPE

static final String NO_TX_TYPE
See Also:
Constant Field Values

LOCAL_TX_TYPE

static final String LOCAL_TX_TYPE
See Also:
Constant Field Values

XA_TX_TYPE

static final String XA_TX_TYPE
See Also:
Constant Field Values

JMQ_TOPIC_CODE

static final String JMQ_TOPIC_CODE
See Also:
Constant Field Values

JMQ_QUEUE_CODE

static final String JMQ_QUEUE_CODE
See Also:
Constant Field Values

MAP_DEFAULT

static final int MAP_DEFAULT
See Also:
Constant Field Values

MAP_SUBTAG

static final int MAP_SUBTAG
See Also:
Constant Field Values

MAP_ATTRIBUTE

static final int MAP_ATTRIBUTE
See Also:
Constant Field Values

LIST_DEFAULT

static final int LIST_DEFAULT
See Also:
Constant Field Values

LIST_SUBTAG

static final int LIST_SUBTAG
See Also:
Constant Field Values

LIST_ATTRIBUTE

static final int LIST_ATTRIBUTE
See Also:
Constant Field Values

SIMPLE_DEFAULT

static final int SIMPLE_DEFAULT
See Also:
Constant Field Values

SIMPLE_SUBTAG

static final int SIMPLE_SUBTAG
See Also:
Constant Field Values

SIMPLE_ATTRIBUTE

static final int SIMPLE_ATTRIBUTE
See Also:
Constant Field Values
Method Detail

loadConfiguration

org.rhq.core.domain.configuration.Configuration loadConfiguration(File file,
                                                                  String name)
This method loads an XML file and converts it into a @see Configuration object

Parameters:
file - @see File object for the xml file to read
name - name of the component to retrieve from the xml file
Returns:
Configuration the Configuration object filled in with all the properties from the xml file for component

updateConfiguration

void updateConfiguration(File deploymentFile,
                         String name,
                         ConfigurationUpdateReport report)
This method will save a Configuration object into the xml file supplied where the component already existing. The

Parameters:
deploymentFile - @see File object for the xml file to updated
name - name of the component in the xml file to save
report - the Plugin's @see ConfigurationUpdateReport that holds the new configuration.
See Also:
will be updated with the success or failure of the update. If there is a failure an error message will be added to the report.

updateConfiguration

void updateConfiguration(File deploymentFile,
                         String name,
                         CreateResourceReport report)
This method will save a Configuration object into the xml file supplied where the component does not already existing. This means this is a new Resource being created, the file may or may not already exist. If it doesn't exist a new file is created, if it does, the configuration will be appended to the file in the appropriate place. The @see CreateResourceReport will be updated with the success or failure of the update. If there is a failure an error message will be added to the report.

Parameters:
deploymentFile - @see File object for the xml file to created or updated
name - name of the component for the xml file to save
report - the Plugin's @see CreateResourceReport that holds the new configuration.

deleteComponent

void deleteComponent(File deploymentFile,
                     String name)
This method will delete a configuration for a component from an xml file.

Parameters:
deploymentFile - @see File object for the xml file to delete from
name - name of the component in the xml file to delete


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