|
|||||||||
| Home >> All >> org >> apache >> struts >> config >> [ impl overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.apache.struts.config.impl
Class ModuleConfigImpl

java.lang.Objectorg.apache.struts.config.impl.ModuleConfigImpl
- All Implemented Interfaces:
- org.apache.struts.config.ModuleConfig, java.io.Serializable
- public class ModuleConfigImpl
- extends java.lang.Object
- implements java.io.Serializable, org.apache.struts.config.ModuleConfig
- extends java.lang.Object
The collection of static configuration information that describes a Struts-based module. Multiple modules are identified by a prefix at the beginning of the context relative portion of the request URI. If no module prefix can be matched, the default configuration (with a prefix equal to a zero-length string) is selected, which is elegantly backwards compatible with the previous Struts behavior that only supported one module.
- Since:
- Struts 1.1
- Version:
- $Rev: 170858 $ $Date: 2005-05-19 03:58:27 +0100 (Thu, 19 May 2005) $
| Field Summary | |
protected java.util.List |
actionConfigList
The set of action configurations for this module, if any, listed in the order in which they are added. |
protected java.util.HashMap |
actionConfigs
The set of action configurations for this module, if any, keyed by the path property. |
protected java.lang.String |
actionFormBeanClass
The default class name to be used when creating action form bean instances. |
protected java.lang.String |
actionForwardClass
The default class name to be used when creating action forward instances. |
protected java.lang.String |
actionMappingClass
The default class name to be used when creating action mapping instances. |
protected boolean |
configured
Has this module been completely configured yet. |
protected org.apache.struts.config.ControllerConfig |
controllerConfig
The controller configuration object for this module. |
protected java.util.HashMap |
dataSources
The set of JDBC data source configurations for this module, if any, keyed by the key property. |
protected java.util.HashMap |
exceptions
The set of exception handling configurations for this module, if any, keyed by the type property. |
protected java.util.HashMap |
formBeans
The set of form bean configurations for this module, if any, keyed by the name property. |
protected java.util.HashMap |
forwards
The set of global forward configurations for this module, if any, keyed by the name property. |
protected org.apache.struts.config.ActionConfigMatcher |
matcher
Matches action config paths against compiled wildcard patterns |
protected java.util.HashMap |
messageResources
The set of message resources configurations for this module, if any, keyed by the key property. |
protected java.util.ArrayList |
plugIns
The set of configured plug-in Actions for this module, if any, in the order they were declared and configured. |
protected java.lang.String |
prefix
The prefix of the context-relative portion of the request URI, used to select this configuration versus others supported by the controller servlet. |
| Constructor Summary | |
ModuleConfigImpl()
Constructor for ModuleConfigImpl. |
|
ModuleConfigImpl(java.lang.String prefix)
Construct an ModuleConfigImpl object according to the specified parameter values. |
|
| Method Summary | |
void |
addActionConfig(org.apache.struts.config.ActionConfig config)
Add a new ActionConfig instance to the set associated
with this module. |
void |
addDataSourceConfig(org.apache.struts.config.DataSourceConfig config)
Add a new DataSourceConfig instance to the set associated
with this module. |
void |
addExceptionConfig(org.apache.struts.config.ExceptionConfig config)
Add a new ExceptionConfig instance to the set associated
with this module. |
void |
addFormBeanConfig(org.apache.struts.config.FormBeanConfig config)
Add a new FormBeanConfig instance to the set associated
with this module. |
void |
addForwardConfig(org.apache.struts.config.ForwardConfig config)
Add a new ForwardConfig instance to the set of global
forwards associated with this module. |
void |
addMessageResourcesConfig(org.apache.struts.config.MessageResourcesConfig config)
Add a new MessageResourcesConfig instance to the set
associated with this module. |
void |
addPlugInConfig(org.apache.struts.config.PlugInConfig plugInConfig)
Add a newly configured org.apache.struts.config.PlugInConfig instance to the set of plug-in Actions for this module. |
org.apache.struts.config.ActionConfig |
findActionConfig(java.lang.String path)
Return the action configuration for the specified path, first looking a direct match, then if none found, a wildcard pattern match; otherwise return null. |
org.apache.struts.config.ActionConfig[] |
findActionConfigs()
Return the action configurations for this module. |
org.apache.struts.config.DataSourceConfig |
findDataSourceConfig(java.lang.String key)
Return the data source configuration for the specified key, if any; otherwise return null. |
org.apache.struts.config.DataSourceConfig[] |
findDataSourceConfigs()
Return the data source configurations for this module. |
org.apache.struts.config.ExceptionConfig |
findExceptionConfig(java.lang.String type)
Return the exception configuration for the specified type, if any; otherwise return null. |
org.apache.struts.config.ExceptionConfig[] |
findExceptionConfigs()
Return the exception configurations for this module. |
org.apache.struts.config.FormBeanConfig |
findFormBeanConfig(java.lang.String name)
Return the form bean configuration for the specified key, if any; otherwise return null. |
org.apache.struts.config.FormBeanConfig[] |
findFormBeanConfigs()
Return the form bean configurations for this module. |
org.apache.struts.config.ForwardConfig |
findForwardConfig(java.lang.String name)
Return the forward configuration for the specified key, if any; otherwise return null. |
org.apache.struts.config.ForwardConfig[] |
findForwardConfigs()
Return the form bean configurations for this module. |
org.apache.struts.config.MessageResourcesConfig |
findMessageResourcesConfig(java.lang.String key)
Return the message resources configuration for the specified key, if any; otherwise return null. |
org.apache.struts.config.MessageResourcesConfig[] |
findMessageResourcesConfigs()
Return the message resources configurations for this module. |
org.apache.struts.config.PlugInConfig[] |
findPlugInConfigs()
Return the configured plug-in actions for this module. |
void |
freeze()
Freeze the configuration of this module. |
java.lang.String |
getActionFormBeanClass()
The default class name to be used when creating action form bean instances. |
java.lang.String |
getActionForwardClass()
The default class name to be used when creating action forward instances. |
java.lang.String |
getActionMappingClass()
The default class name to be used when creating action mapping instances. |
boolean |
getConfigured()
Has this module been completely configured yet. |
org.apache.struts.config.ControllerConfig |
getControllerConfig()
The controller configuration object for this module. |
java.lang.String |
getPrefix()
The prefix of the context-relative portion of the request URI, used to select this configuration versus others supported by the controller servlet. |
void |
removeActionConfig(org.apache.struts.config.ActionConfig config)
Remove the specified action configuration instance. |
void |
removeDataSourceConfig(org.apache.struts.config.DataSourceConfig config)
Remove the specified data source configuration instance. |
void |
removeExceptionConfig(org.apache.struts.config.ExceptionConfig config)
Remove the specified exception configuration instance. |
void |
removeFormBeanConfig(org.apache.struts.config.FormBeanConfig config)
Remove the specified form bean configuration instance. |
void |
removeForwardConfig(org.apache.struts.config.ForwardConfig config)
Remove the specified forward configuration instance. |
void |
removeMessageResourcesConfig(org.apache.struts.config.MessageResourcesConfig config)
Remove the specified message resources configuration instance. |
void |
setActionFormBeanClass(java.lang.String actionFormBeanClass)
The default class name to be used when creating action form bean instances. |
void |
setActionForwardClass(java.lang.String actionForwardClass)
The default class name to be used when creating action forward instances. |
void |
setActionMappingClass(java.lang.String actionMappingClass)
The default class name to be used when creating action mapping instances. |
void |
setControllerConfig(org.apache.struts.config.ControllerConfig cc)
The controller configuration object for this module. |
void |
setPrefix(java.lang.String prefix)
The prefix of the context-relative portion of the request URI, used to select this configuration versus others supported by the controller servlet. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
actionConfigs
protected java.util.HashMap actionConfigs
- The set of action configurations for this module, if any,
keyed by the
pathproperty.
actionConfigList
protected java.util.List actionConfigList
- The set of action configurations for this module, if any,
listed in the order in which they are added.
dataSources
protected java.util.HashMap dataSources
- The set of JDBC data source configurations for this
module, if any, keyed by the
keyproperty.
exceptions
protected java.util.HashMap exceptions
- The set of exception handling configurations for this
module, if any, keyed by the
typeproperty.
formBeans
protected java.util.HashMap formBeans
- The set of form bean configurations for this module, if any,
keyed by the
nameproperty.
forwards
protected java.util.HashMap forwards
- The set of global forward configurations for this module, if any,
keyed by the
nameproperty.
messageResources
protected java.util.HashMap messageResources
- The set of message resources configurations for this
module, if any, keyed by the
keyproperty.
plugIns
protected java.util.ArrayList plugIns
- The set of configured plug-in Actions for this module,
if any, in the order they were declared and configured.
configured
protected boolean configured
- Has this module been completely configured yet. Once this flag
has been set, any attempt to modify the configuration will return an
IllegalStateException.
controllerConfig
protected org.apache.struts.config.ControllerConfig controllerConfig
- The controller configuration object for this module.
prefix
protected java.lang.String prefix
- The prefix of the context-relative portion of the request URI, used to
select this configuration versus others supported by the controller
servlet. A configuration with a prefix of a zero-length String is the
default configuration for this web module.
actionFormBeanClass
protected java.lang.String actionFormBeanClass
- The default class name to be used when creating action form bean
instances.
actionMappingClass
protected java.lang.String actionMappingClass
- The default class name to be used when creating action mapping instances.
actionForwardClass
protected java.lang.String actionForwardClass
- The default class name to be used when creating action forward instances.
matcher
protected org.apache.struts.config.ActionConfigMatcher matcher
- Matches action config paths against compiled wildcard patterns
| Constructor Detail |
ModuleConfigImpl
public ModuleConfigImpl()
- Constructor for ModuleConfigImpl. Assumes default configuration.
- Since:
- Struts 1.2.8
ModuleConfigImpl
public ModuleConfigImpl(java.lang.String prefix)
- Construct an ModuleConfigImpl object according to the specified
parameter values.
| Method Detail |
getConfigured
public boolean getConfigured()
- Has this module been completely configured yet. Once this flag
has been set, any attempt to modify the configuration will return an
IllegalStateException.
- Specified by:
getConfiguredin interfaceorg.apache.struts.config.ModuleConfig
getControllerConfig
public org.apache.struts.config.ControllerConfig getControllerConfig()
- The controller configuration object for this module.
- Specified by:
getControllerConfigin interfaceorg.apache.struts.config.ModuleConfig
setControllerConfig
public void setControllerConfig(org.apache.struts.config.ControllerConfig cc)
- The controller configuration object for this module.
- Specified by:
setControllerConfigin interfaceorg.apache.struts.config.ModuleConfig
getPrefix
public java.lang.String getPrefix()
- The prefix of the context-relative portion of the request URI, used to
select this configuration versus others supported by the controller
servlet. A configuration with a prefix of a zero-length String is the
default configuration for this web module.
- Specified by:
getPrefixin interfaceorg.apache.struts.config.ModuleConfig
setPrefix
public void setPrefix(java.lang.String prefix)
- The prefix of the context-relative portion of the request URI, used to
select this configuration versus others supported by the controller
servlet. A configuration with a prefix of a zero-length String is the
default configuration for this web module.
- Specified by:
setPrefixin interfaceorg.apache.struts.config.ModuleConfig
getActionFormBeanClass
public java.lang.String getActionFormBeanClass()
- The default class name to be used when creating action form bean
instances.
- Specified by:
getActionFormBeanClassin interfaceorg.apache.struts.config.ModuleConfig
setActionFormBeanClass
public void setActionFormBeanClass(java.lang.String actionFormBeanClass)
- The default class name to be used when creating action form bean
instances.
- Specified by:
setActionFormBeanClassin interfaceorg.apache.struts.config.ModuleConfig
getActionMappingClass
public java.lang.String getActionMappingClass()
- The default class name to be used when creating action mapping instances.
- Specified by:
getActionMappingClassin interfaceorg.apache.struts.config.ModuleConfig
setActionMappingClass
public void setActionMappingClass(java.lang.String actionMappingClass)
- The default class name to be used when creating action mapping instances.
- Specified by:
setActionMappingClassin interfaceorg.apache.struts.config.ModuleConfig
addActionConfig
public void addActionConfig(org.apache.struts.config.ActionConfig config)
- Add a new
ActionConfiginstance to the set associated with this module.- Specified by:
addActionConfigin interfaceorg.apache.struts.config.ModuleConfig
addDataSourceConfig
public void addDataSourceConfig(org.apache.struts.config.DataSourceConfig config)
- Add a new
DataSourceConfiginstance to the set associated with this module.- Specified by:
addDataSourceConfigin interfaceorg.apache.struts.config.ModuleConfig
addExceptionConfig
public void addExceptionConfig(org.apache.struts.config.ExceptionConfig config)
- Add a new
ExceptionConfiginstance to the set associated with this module.- Specified by:
addExceptionConfigin interfaceorg.apache.struts.config.ModuleConfig
addFormBeanConfig
public void addFormBeanConfig(org.apache.struts.config.FormBeanConfig config)
- Add a new
FormBeanConfiginstance to the set associated with this module.- Specified by:
addFormBeanConfigin interfaceorg.apache.struts.config.ModuleConfig
getActionForwardClass
public java.lang.String getActionForwardClass()
- The default class name to be used when creating action forward instances.
- Specified by:
getActionForwardClassin interfaceorg.apache.struts.config.ModuleConfig
setActionForwardClass
public void setActionForwardClass(java.lang.String actionForwardClass)
- The default class name to be used when creating action forward instances.
- Specified by:
setActionForwardClassin interfaceorg.apache.struts.config.ModuleConfig
addForwardConfig
public void addForwardConfig(org.apache.struts.config.ForwardConfig config)
- Add a new
ForwardConfiginstance to the set of global forwards associated with this module.- Specified by:
addForwardConfigin interfaceorg.apache.struts.config.ModuleConfig
addMessageResourcesConfig
public void addMessageResourcesConfig(org.apache.struts.config.MessageResourcesConfig config)
- Add a new
MessageResourcesConfiginstance to the set associated with this module.- Specified by:
addMessageResourcesConfigin interfaceorg.apache.struts.config.ModuleConfig
addPlugInConfig
public void addPlugInConfig(org.apache.struts.config.PlugInConfig plugInConfig)
- Add a newly configured org.apache.struts.config.PlugInConfig instance to the set of
plug-in Actions for this module.
- Specified by:
addPlugInConfigin interfaceorg.apache.struts.config.ModuleConfig
findActionConfig
public org.apache.struts.config.ActionConfig findActionConfig(java.lang.String path)
- Return the action configuration for the specified path, first looking
a direct match, then if none found, a wildcard pattern match;
otherwise return
null.- Specified by:
findActionConfigin interfaceorg.apache.struts.config.ModuleConfig
findActionConfigs
public org.apache.struts.config.ActionConfig[] findActionConfigs()
- Return the action configurations for this module. If there are
none, a zero-length array is returned.
- Specified by:
findActionConfigsin interfaceorg.apache.struts.config.ModuleConfig
findDataSourceConfig
public org.apache.struts.config.DataSourceConfig findDataSourceConfig(java.lang.String key)
- Return the data source configuration for the specified key, if any;
otherwise return
null.- Specified by:
findDataSourceConfigin interfaceorg.apache.struts.config.ModuleConfig
findDataSourceConfigs
public org.apache.struts.config.DataSourceConfig[] findDataSourceConfigs()
- Return the data source configurations for this module. If there
are none, a zero-length array is returned.
- Specified by:
findDataSourceConfigsin interfaceorg.apache.struts.config.ModuleConfig
findExceptionConfig
public org.apache.struts.config.ExceptionConfig findExceptionConfig(java.lang.String type)
- Return the exception configuration for the specified type, if any;
otherwise return
null.- Specified by:
findExceptionConfigin interfaceorg.apache.struts.config.ModuleConfig
findExceptionConfigs
public org.apache.struts.config.ExceptionConfig[] findExceptionConfigs()
- Return the exception configurations for this module. If there
are none, a zero-length array is returned.
- Specified by:
findExceptionConfigsin interfaceorg.apache.struts.config.ModuleConfig
findFormBeanConfig
public org.apache.struts.config.FormBeanConfig findFormBeanConfig(java.lang.String name)
- Return the form bean configuration for the specified key, if any;
otherwise return
null.- Specified by:
findFormBeanConfigin interfaceorg.apache.struts.config.ModuleConfig
findFormBeanConfigs
public org.apache.struts.config.FormBeanConfig[] findFormBeanConfigs()
- Return the form bean configurations for this module. If there
are none, a zero-length array is returned.
- Specified by:
findFormBeanConfigsin interfaceorg.apache.struts.config.ModuleConfig
findForwardConfig
public org.apache.struts.config.ForwardConfig findForwardConfig(java.lang.String name)
- Return the forward configuration for the specified key, if any;
otherwise return
null.- Specified by:
findForwardConfigin interfaceorg.apache.struts.config.ModuleConfig
findForwardConfigs
public org.apache.struts.config.ForwardConfig[] findForwardConfigs()
- Return the form bean configurations for this module. If there
are none, a zero-length array is returned.
- Specified by:
findForwardConfigsin interfaceorg.apache.struts.config.ModuleConfig
findMessageResourcesConfig
public org.apache.struts.config.MessageResourcesConfig findMessageResourcesConfig(java.lang.String key)
- Return the message resources configuration for the specified key,
if any; otherwise return
null.- Specified by:
findMessageResourcesConfigin interfaceorg.apache.struts.config.ModuleConfig
findMessageResourcesConfigs
public org.apache.struts.config.MessageResourcesConfig[] findMessageResourcesConfigs()
- Return the message resources configurations for this module.
If there are none, a zero-length array is returned.
- Specified by:
findMessageResourcesConfigsin interfaceorg.apache.struts.config.ModuleConfig
findPlugInConfigs
public org.apache.struts.config.PlugInConfig[] findPlugInConfigs()
- Return the configured plug-in actions for this module. If there
are none, a zero-length array is returned.
- Specified by:
findPlugInConfigsin interfaceorg.apache.struts.config.ModuleConfig
freeze
public void freeze()
- Freeze the configuration of this module. After this method
returns, any attempt to modify the configuration will return
an IllegalStateException.
- Specified by:
freezein interfaceorg.apache.struts.config.ModuleConfig
removeActionConfig
public void removeActionConfig(org.apache.struts.config.ActionConfig config)
- Remove the specified action configuration instance.
- Specified by:
removeActionConfigin interfaceorg.apache.struts.config.ModuleConfig
removeExceptionConfig
public void removeExceptionConfig(org.apache.struts.config.ExceptionConfig config)
- Remove the specified exception configuration instance.
- Specified by:
removeExceptionConfigin interfaceorg.apache.struts.config.ModuleConfig
removeDataSourceConfig
public void removeDataSourceConfig(org.apache.struts.config.DataSourceConfig config)
- Remove the specified data source configuration instance.
- Specified by:
removeDataSourceConfigin interfaceorg.apache.struts.config.ModuleConfig
removeFormBeanConfig
public void removeFormBeanConfig(org.apache.struts.config.FormBeanConfig config)
- Remove the specified form bean configuration instance.
- Specified by:
removeFormBeanConfigin interfaceorg.apache.struts.config.ModuleConfig
removeForwardConfig
public void removeForwardConfig(org.apache.struts.config.ForwardConfig config)
- Remove the specified forward configuration instance.
- Specified by:
removeForwardConfigin interfaceorg.apache.struts.config.ModuleConfig
removeMessageResourcesConfig
public void removeMessageResourcesConfig(org.apache.struts.config.MessageResourcesConfig config)
- Remove the specified message resources configuration instance.
- Specified by:
removeMessageResourcesConfigin interfaceorg.apache.struts.config.ModuleConfig
|
|||||||||
| Home >> All >> org >> apache >> struts >> config >> [ impl overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
org.apache.struts.config.impl.ModuleConfigImpl