Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.opensymphony.xwork2.config.impl
Class DefaultConfiguration

    java.lang.Object
      com.opensymphony.xwork2.config.impl.DefaultConfiguration

All Implemented Interfaces:
  Configuration, Serializable

    public class DefaultConfiguration

extends Object
implements Configuration

DefaultConfiguration

Author:
  Jason Carreira Created Feb 24, 2003 7:38:06 AM
See Also:
  Serialized Form

Nested Class Summary
`(package private) class` | `DefaultConfiguration.ContainerProperties`
`private class` | `DefaultConfiguration.RuntimeConfigurationImpl`

Field Summary
`protected Container` | `container`
`protected String` | `defaultFrameworkBeanName`
`protected Set<String>` | `loadedFileNames`
`protected static Log` | `LOG`
`(package private) ObjectFactory` | `objectFactory`
`protected Map<String,PackageConfig>` | `packageContexts`
`protected RuntimeConfiguration` | `runtimeConfiguration`

Constructor Summary
`DefaultConfiguration()`
`DefaultConfiguration(String defaultBeanName)`

Method Summary
`void` | `addPackageConfig(String name, PackageConfig packageContext)`
`private ActionConfig` | `buildFullActionConfig(PackageConfig packageContext, ActionConfig baseConfig)` Builds the full runtime actionconfig with all of the defaults and inheritance
`protected RuntimeConfiguration` | `buildRuntimeConfiguration()` This methodName builds the internal runtime configuration used by Xwork for finding and configuring Actions from the programmatic configuration data structures.
`void` | `destroy()` Allows the configuration to clean up any resources used
`Container` | `getContainer()`
`Set<String>` | `getLoadedFileNames()`
`PackageConfig` | `getPackageConfig(String name)`
`Set` | `getPackageConfigNames()`
`Map` | `getPackageConfigs()`
`RuntimeConfiguration` | `getRuntimeConfiguration()` The current runtime configuration.
`void` | `rebuildRuntimeConfiguration()`
`void` | `reload(List<ConfigurationProvider> providers)` Calls the ConfigurationProviderFactory.getConfig() to tell it to reload the configuration and then calls buildRuntimeConfiguration().
`void` | `removePackageConfig(String name)`
`private void` | `setDefaultResults(Map<String,ResultConfig> results, PackageConfig packageContext)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### LOG

    protected static final Log LOG

### packageContexts

    protected Map<String,PackageConfig> packageContexts

### runtimeConfiguration

    protected RuntimeConfiguration runtimeConfiguration

### container

    protected Container container

### defaultFrameworkBeanName

    protected String defaultFrameworkBeanName

### loadedFileNames

    protected Set<String> loadedFileNames

### objectFactory

    ObjectFactory objectFactory

Constructor Detail

### DefaultConfiguration

    public DefaultConfiguration()

### DefaultConfiguration

    public DefaultConfiguration(String defaultBeanName)

Method Detail

### getPackageConfig

    public PackageConfig getPackageConfig(String name)

  Specified by:
    `getPackageConfig` in interface `Configuration`

### getPackageConfigNames

    public Set getPackageConfigNames()

  Specified by:
    `getPackageConfigNames` in interface `Configuration`

### getPackageConfigs

    public Map getPackageConfigs()

  Specified by:
    `getPackageConfigs` in interface `Configuration`

### getLoadedFileNames

    public Set<String> getLoadedFileNames()

  Specified by:
    `getLoadedFileNames` in interface `Configuration`

### getRuntimeConfiguration

    public RuntimeConfiguration getRuntimeConfiguration()

  Description copied from interface: `Configuration`
  The current runtime configuration. Currently, if changes have been made to the Configuration since the last time buildRuntimeConfiguration() was called, you'll need to make sure to.

  Specified by:
    `getRuntimeConfiguration` in interface `Configuration`
  Returns:
    the current runtime configuration

### getContainer

    public Container getContainer()

  Specified by:
    `getContainer` in interface `Configuration`
  Returns:
    the container

### addPackageConfig

    public void addPackageConfig(String name,
                                 PackageConfig packageContext)

  Specified by:
    `addPackageConfig` in interface `Configuration`

### destroy

    public void destroy()

  Allows the configuration to clean up any resources used

  Specified by:
    `destroy` in interface `Configuration`

### rebuildRuntimeConfiguration

    public void rebuildRuntimeConfiguration()

  Specified by:
    `rebuildRuntimeConfiguration` in interface `Configuration`

### reload

    public void reload(List<ConfigurationProvider> providers)
                throws ConfigurationException

  Calls the ConfigurationProviderFactory.getConfig() to tell it to reload the configuration and then calls buildRuntimeConfiguration().

  Specified by:
    `reload` in interface `Configuration`
  Throws:
    `ConfigurationException`

### removePackageConfig

    public void removePackageConfig(String name)

  Specified by:
    `removePackageConfig` in interface `Configuration`

### buildRuntimeConfiguration

    protected RuntimeConfiguration buildRuntimeConfiguration()
                                                      throws ConfigurationException

  This methodName builds the internal runtime configuration used by Xwork for finding and configuring Actions from the programmatic configuration data structures. All of the old runtime configuration will be discarded and rebuilt.

  Throws:
    `ConfigurationException`

### setDefaultResults

    private void setDefaultResults(Map<String,ResultConfig> results,
                                   PackageConfig packageContext)

### buildFullActionConfig

    private ActionConfig buildFullActionConfig(PackageConfig packageContext,
                                               ActionConfig baseConfig)
                                        throws ConfigurationException

  Builds the full runtime actionconfig with all of the defaults and inheritance

  Parameters:
    `packageContext` - the PackageConfig which holds the base config we're building from
    `baseConfig` - the ActionConfig which holds only the configuration specific to itself, without the defaults and inheritance
  Returns:
    a full ActionConfig for runtime configuration with all of the inherited and default params
  Throws:
    `ConfigurationException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000-2007 Apache Software Foundation. All Rights Reserved.