org.mule.config.builders
Class MuleXmlConfigurationBuilder

java.lang.Object
  extended by org.mule.config.builders.AbstractDigesterConfiguration
      extended by org.mule.config.builders.MuleXmlConfigurationBuilder
All Implemented Interfaces:
ConfigurationBuilder
Direct Known Subclasses:
MuleClasspathConfigurationBuilder, WebappMuleXmlConfigurationBuilder

public class MuleXmlConfigurationBuilder
extends AbstractDigesterConfiguration
implements ConfigurationBuilder

MuleXmlConfigurationBuilder is a configuration parser that builds a MuleManager instance based on a mule xml configration file defined in the mule-configuration.dtd.


Nested Class Summary
 class MuleXmlConfigurationBuilder.ExtendedMuleSetPropertiesRule
          this rule serves 2 functions - 1.
 
Field Summary
static String AGENT_INTERFACE
           
static String CONNECTION_STRATEGY_INTERFACE
           
static String CONNECTOR_INTERFACE
           
static String DEFAULT_CATCH_ALL_STRATEGY
           
static String DEFAULT_DESCRIPTOR
           
static String DEFAULT_ENDPOINT
           
static String DEFAULT_ENTRY_POINT_RESOLVER
           
static String DEFAULT_INBOUND_ROUTER_COLLECTION
           
static String DEFAULT_LIFECYCLE_ADAPTER
           
static String DEFAULT_NESTED_ROUTER
           
static String DEFAULT_NESTED_ROUTER_COLLECTION
           
static String DEFAULT_OUTBOUND_ROUTER_COLLECTION
           
static String DEFAULT_POOL_FACTORY
           
static String DEFAULT_RESPONSE_ROUTER_COLLECTION
           
static String DEFAULT_SECURITY_MANAGER
           
static String DEFAULT_TRANSACTION_CONFIG
           
static String ENCRYPTION_STRATEGY_INTERFACE
           
static String ENDPOINT_SECURITY_FILTER_INTERFACE
           
static String EXCEPTION_STRATEGY_INTERFACE
           
static String INBOUND_MESSAGE_ROUTER_INTERFACE
           
static String INTERCEPTOR_INTERFACE
           
protected  UMOManager manager
           
static String NESTED_MESSAGE_ROUTER_INTERFACE
           
static String OUTBOUND_MESSAGE_ROUTER_INTERFACE
           
static String PERSISTENCE_STRATEGY_INTERFACE
           
static String POOLING_PROFILE
           
static String QUEUE_PROFILE
           
static String RESPONSE_MESSAGE_ROUTER_INTERFACE
           
static String ROUTER_INTERFACE
           
static String SECURITY_PROVIDER_INTERFACE
           
static String THREADING_PROFILE
           
static String TRANSACTION_CONSTRAINT_INTERFACE
           
static String TRANSACTION_FACTORY_INTERFACE
           
static String TRANSACTION_MANAGER_FACTORY_INTERFACE
           
static String TRANSFORMER_INTERFACE
           
 
Fields inherited from class org.mule.config.builders.AbstractDigesterConfiguration
configEncoding, containerReferences, DEFAULT_CONTAINER_CONTEXT, digester, FILTER_INTERFACE, logger
 
Constructor Summary
MuleXmlConfigurationBuilder()
           
 
Method Summary
protected  void addAgentRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addCommonEndpointRules(org.apache.commons.digester.Digester digester, String path, String method)
           
protected  void addConnectorRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addEndpointIdentifierRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addEndpointRules(org.apache.commons.digester.Digester digester, String path, String method)
           
protected  void addExceptionStrategyRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addGlobalEndpointRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addGlobalReferenceEndpointRules(org.apache.commons.digester.Digester digester, String path, String method)
           
protected  void addInterceptorStackRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addManagerRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addMessageRouterRules(org.apache.commons.digester.Digester digester, String path, String type)
           
protected  void addModelRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addMuleConfigurationRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addMuleDescriptorRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addObjectCreateOrGetFromContainer(String path, String defaultImpl, String classAttrib, String refAttrib, boolean classRefRequired)
           
protected  void addObjectCreateOrGetFromContainer(String path, String defaultImpl, String classAttrib, String refAttrib, String containerAttrib, boolean classRefRequired)
           
protected  void addPoolingProfileRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addQueueProfileRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addReplyToRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addRouterRules(org.apache.commons.digester.Digester digester, String path, String type)
           
protected  void addSecurityManagerRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addSetPropertiesRule(String path, org.apache.commons.digester.Digester digester)
           
protected  void addSetPropertiesRule(String path, org.apache.commons.digester.Digester digester, String[] s1, String[] s2)
           
protected  void addThreadingProfileRules(org.apache.commons.digester.Digester digester, String path, String type)
           
protected  void addTransactionConfigRules(String path, org.apache.commons.digester.Digester digester)
           
protected  void addTransactionManagerRules(org.apache.commons.digester.Digester digester, String path)
           
protected  void addTransformerRules(org.apache.commons.digester.Digester digester, String path)
           
 UMOManager configure(ReaderResource[] configResources)
          Deprecated. Please use configure(ReaderResource[] configResources, Properties startupProperties) instead.
 UMOManager configure(ReaderResource[] configResources, Properties startupProperties)
          Will configure a UMOManager based on the configurations made available through Readers
 UMOManager configure(String configResources)
          Will configure a UMOManager based on the configuration file(s) provided.
 UMOManager configure(String configResources, String startupPropertiesFile)
          Will configure a UMOManager based on the configuration file(s) provided.
 String getRootName()
           
 boolean isConfigured()
          Indicate whether this ConfigurationBulder has been configured yet
protected  InputStream loadResource(String configResource)
          Override this method to provide alternative ways of loading a resource.
protected  void setContainerProperties()
           
protected  void setGlobalEndpoints()
           
protected  void setTransformers()
           
 
Methods inherited from class org.mule.config.builders.AbstractDigesterConfiguration
addContainerContextRules, addFilterGroupRule, addFilterRules, addLeftFilterRule, addMulePropertiesRule, addMulePropertiesRule, addMulePropertiesRule, addRightFilterRule, addServerPropertiesRules, addSingleFilterRule, process
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_ENTRY_POINT_RESOLVER

public static final String DEFAULT_ENTRY_POINT_RESOLVER

DEFAULT_LIFECYCLE_ADAPTER

public static final String DEFAULT_LIFECYCLE_ADAPTER

DEFAULT_ENDPOINT

public static final String DEFAULT_ENDPOINT

DEFAULT_TRANSACTION_CONFIG

public static final String DEFAULT_TRANSACTION_CONFIG

DEFAULT_DESCRIPTOR

public static final String DEFAULT_DESCRIPTOR

DEFAULT_SECURITY_MANAGER

public static final String DEFAULT_SECURITY_MANAGER

DEFAULT_OUTBOUND_ROUTER_COLLECTION

public static final String DEFAULT_OUTBOUND_ROUTER_COLLECTION

DEFAULT_INBOUND_ROUTER_COLLECTION

public static final String DEFAULT_INBOUND_ROUTER_COLLECTION

DEFAULT_NESTED_ROUTER_COLLECTION

public static final String DEFAULT_NESTED_ROUTER_COLLECTION

DEFAULT_RESPONSE_ROUTER_COLLECTION

public static final String DEFAULT_RESPONSE_ROUTER_COLLECTION

DEFAULT_NESTED_ROUTER

public static final String DEFAULT_NESTED_ROUTER

DEFAULT_CATCH_ALL_STRATEGY

public static final String DEFAULT_CATCH_ALL_STRATEGY

DEFAULT_POOL_FACTORY

public static final String DEFAULT_POOL_FACTORY

THREADING_PROFILE

public static final String THREADING_PROFILE

POOLING_PROFILE

public static final String POOLING_PROFILE

QUEUE_PROFILE

public static final String QUEUE_PROFILE

PERSISTENCE_STRATEGY_INTERFACE

public static final String PERSISTENCE_STRATEGY_INTERFACE

INBOUND_MESSAGE_ROUTER_INTERFACE

public static final String INBOUND_MESSAGE_ROUTER_INTERFACE

NESTED_MESSAGE_ROUTER_INTERFACE

public static final String NESTED_MESSAGE_ROUTER_INTERFACE

RESPONSE_MESSAGE_ROUTER_INTERFACE

public static final String RESPONSE_MESSAGE_ROUTER_INTERFACE

OUTBOUND_MESSAGE_ROUTER_INTERFACE

public static final String OUTBOUND_MESSAGE_ROUTER_INTERFACE

TRANSFORMER_INTERFACE

public static final String TRANSFORMER_INTERFACE

TRANSACTION_MANAGER_FACTORY_INTERFACE

public static final String TRANSACTION_MANAGER_FACTORY_INTERFACE

SECURITY_PROVIDER_INTERFACE

public static final String SECURITY_PROVIDER_INTERFACE

ENCRYPTION_STRATEGY_INTERFACE

public static final String ENCRYPTION_STRATEGY_INTERFACE

ENDPOINT_SECURITY_FILTER_INTERFACE

public static final String ENDPOINT_SECURITY_FILTER_INTERFACE

AGENT_INTERFACE

public static final String AGENT_INTERFACE

TRANSACTION_FACTORY_INTERFACE

public static final String TRANSACTION_FACTORY_INTERFACE

TRANSACTION_CONSTRAINT_INTERFACE

public static final String TRANSACTION_CONSTRAINT_INTERFACE

CONNECTOR_INTERFACE

public static final String CONNECTOR_INTERFACE

INTERCEPTOR_INTERFACE

public static final String INTERCEPTOR_INTERFACE

ROUTER_INTERFACE

public static final String ROUTER_INTERFACE

EXCEPTION_STRATEGY_INTERFACE

public static final String EXCEPTION_STRATEGY_INTERFACE

CONNECTION_STRATEGY_INTERFACE

public static final String CONNECTION_STRATEGY_INTERFACE

manager

protected UMOManager manager
Constructor Detail

MuleXmlConfigurationBuilder

public MuleXmlConfigurationBuilder()
                            throws ConfigurationException
Throws:
ConfigurationException
Method Detail

getRootName

public String getRootName()
Specified by:
getRootName in class AbstractDigesterConfiguration

configure

public UMOManager configure(String configResources)
                     throws ConfigurationException
Description copied from interface: ConfigurationBuilder
Will configure a UMOManager based on the configuration file(s) provided.

Specified by:
configure in interface ConfigurationBuilder
Parameters:
configResources - a comma separated list of configuration files to load, this should be accessible on the classpath or filesystem
Returns:
A configured UMOManager
Throws:
ConfigurationException

configure

public UMOManager configure(String configResources,
                            String startupPropertiesFile)
                     throws ConfigurationException
Description copied from interface: ConfigurationBuilder
Will configure a UMOManager based on the configuration file(s) provided.

Specified by:
configure in interface ConfigurationBuilder
Parameters:
configResources - - A comma-separated list of configuration files to load, these should be accessible on the classpath or filesystem
startupPropertiesFile - - An optional file containing startup properties. This is useful for managing different environments (dev, test, production)
Returns:
A configured UMOManager
Throws:
ConfigurationException

loadResource

protected InputStream loadResource(String configResource)
                            throws ConfigurationException
Override this method to provide alternative ways of loading a resource.

Throws:
ConfigurationException

configure

public UMOManager configure(ReaderResource[] configResources)
                     throws ConfigurationException
Deprecated. Please use configure(ReaderResource[] configResources, Properties startupProperties) instead.

Throws:
ConfigurationException

configure

public UMOManager configure(ReaderResource[] configResources,
                            Properties startupProperties)
                     throws ConfigurationException
Description copied from interface: ConfigurationBuilder
Will configure a UMOManager based on the configurations made available through Readers

Specified by:
configure in interface ConfigurationBuilder
Parameters:
configResources - - An array of Readers, each Reader contains a portion of the Mule server configuration.
startupProperties - - Optional properties to be set before configuring the Mule server. This is useful for managing different environments (dev, test, production)
Returns:
A configured UMOManager
Throws:
ConfigurationException

isConfigured

public boolean isConfigured()
Indicate whether this ConfigurationBulder has been configured yet

Specified by:
isConfigured in interface ConfigurationBuilder
Returns:
true if this ConfigurationBulder has been configured

setContainerProperties

protected void setContainerProperties()
                               throws ContainerException
Throws:
ContainerException

setTransformers

protected void setTransformers()
                        throws InitialisationException
Throws:
InitialisationException

setGlobalEndpoints

protected void setGlobalEndpoints()
                           throws InitialisationException
Throws:
InitialisationException

addManagerRules

protected void addManagerRules(org.apache.commons.digester.Digester digester,
                               String path)

addMuleConfigurationRules

protected void addMuleConfigurationRules(org.apache.commons.digester.Digester digester,
                                         String path)

addSecurityManagerRules

protected void addSecurityManagerRules(org.apache.commons.digester.Digester digester,
                                       String path)
                                throws ConfigurationException
Throws:
ConfigurationException

addTransformerRules

protected void addTransformerRules(org.apache.commons.digester.Digester digester,
                                   String path)
                            throws ConfigurationException
Throws:
ConfigurationException

addGlobalEndpointRules

protected void addGlobalEndpointRules(org.apache.commons.digester.Digester digester,
                                      String path)
                               throws ConfigurationException
Throws:
ConfigurationException

addEndpointIdentifierRules

protected void addEndpointIdentifierRules(org.apache.commons.digester.Digester digester,
                                          String path)
                                   throws ConfigurationException
Throws:
ConfigurationException

addTransactionManagerRules

protected void addTransactionManagerRules(org.apache.commons.digester.Digester digester,
                                          String path)
                                   throws ConfigurationException
Throws:
ConfigurationException

addAgentRules

protected void addAgentRules(org.apache.commons.digester.Digester digester,
                             String path)
                      throws ConfigurationException
Throws:
ConfigurationException

addConnectorRules

protected void addConnectorRules(org.apache.commons.digester.Digester digester,
                                 String path)
                          throws ConfigurationException
Throws:
ConfigurationException

addInterceptorStackRules

protected void addInterceptorStackRules(org.apache.commons.digester.Digester digester,
                                        String path)
                                 throws ConfigurationException
Throws:
ConfigurationException

addModelRules

protected void addModelRules(org.apache.commons.digester.Digester digester,
                             String path)
                      throws ConfigurationException
Throws:
ConfigurationException

addMuleDescriptorRules

protected void addMuleDescriptorRules(org.apache.commons.digester.Digester digester,
                                      String path)
                               throws ConfigurationException
Throws:
ConfigurationException

addThreadingProfileRules

protected void addThreadingProfileRules(org.apache.commons.digester.Digester digester,
                                        String path,
                                        String type)

addPoolingProfileRules

protected void addPoolingProfileRules(org.apache.commons.digester.Digester digester,
                                      String path)

addQueueProfileRules

protected void addQueueProfileRules(org.apache.commons.digester.Digester digester,
                                    String path)

addMessageRouterRules

protected void addMessageRouterRules(org.apache.commons.digester.Digester digester,
                                     String path,
                                     String type)
                              throws ConfigurationException
Throws:
ConfigurationException

addRouterRules

protected void addRouterRules(org.apache.commons.digester.Digester digester,
                              String path,
                              String type)
                       throws ConfigurationException
Throws:
ConfigurationException

addReplyToRules

protected void addReplyToRules(org.apache.commons.digester.Digester digester,
                               String path)
                        throws ConfigurationException
Throws:
ConfigurationException

addEndpointRules

protected void addEndpointRules(org.apache.commons.digester.Digester digester,
                                String path,
                                String method)
                         throws ConfigurationException
Throws:
ConfigurationException

addGlobalReferenceEndpointRules

protected void addGlobalReferenceEndpointRules(org.apache.commons.digester.Digester digester,
                                               String path,
                                               String method)
                                        throws ConfigurationException
Throws:
ConfigurationException

addCommonEndpointRules

protected void addCommonEndpointRules(org.apache.commons.digester.Digester digester,
                                      String path,
                                      String method)
                               throws ConfigurationException
Throws:
ConfigurationException

addTransactionConfigRules

protected void addTransactionConfigRules(String path,
                                         org.apache.commons.digester.Digester digester)

addExceptionStrategyRules

protected void addExceptionStrategyRules(org.apache.commons.digester.Digester digester,
                                         String path)
                                  throws ConfigurationException
Throws:
ConfigurationException

addSetPropertiesRule

protected void addSetPropertiesRule(String path,
                                    org.apache.commons.digester.Digester digester,
                                    String[] s1,
                                    String[] s2)
Overrides:
addSetPropertiesRule in class AbstractDigesterConfiguration

addSetPropertiesRule

protected void addSetPropertiesRule(String path,
                                    org.apache.commons.digester.Digester digester)
Overrides:
addSetPropertiesRule in class AbstractDigesterConfiguration

addObjectCreateOrGetFromContainer

protected void addObjectCreateOrGetFromContainer(String path,
                                                 String defaultImpl,
                                                 String classAttrib,
                                                 String refAttrib,
                                                 boolean classRefRequired)

addObjectCreateOrGetFromContainer

protected void addObjectCreateOrGetFromContainer(String path,
                                                 String defaultImpl,
                                                 String classAttrib,
                                                 String refAttrib,
                                                 String containerAttrib,
                                                 boolean classRefRequired)


Copyright © 2003-2008 MuleSource, Inc.. All Rights Reserved.