Java Doc for ModuleConfigImpl.java in  » Web-Framework » struts-1.3.8 » org » apache » struts » config » impl » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Framework » struts 1.3.8 » org.apache.struts.config.impl 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.struts.config.BaseConfig
      org.apache.struts.config.impl.ModuleConfigImpl

ModuleConfigImpl
public class ModuleConfigImpl extends BaseConfig implements Serializable,ModuleConfig(Code)

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.


version:
   $Rev: 471754 $ $Date: 2005-12-31 03:57:16 -0500 (Sat, 31 Dec 2005)
version:
   $
since:
   Struts 1.1


Field Summary
protected  HashMapactionConfigIds
    
protected  ListactionConfigList
    
protected  HashMapactionConfigs
    
protected  StringactionFormBeanClass
    
protected  StringactionForwardClass
     The default class name to be used when creating action forward instances.
protected  StringactionMappingClass
     The default class name to be used when creating action mapping instances.
protected  ControllerConfigcontrollerConfig
    
protected  HashMapexceptions
    
protected  HashMapformBeans
    
protected  HashMapforwards
    
protected static  Loglog
    

Commons Logging instance.

protected  ActionConfigMatchermatcher
    
protected  HashMapmessageResources
    
protected  ArrayListplugIns
    
protected  Stringprefix
    

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
public  ModuleConfigImpl()
    

Constructor for ModuleConfigImpl.

public  ModuleConfigImpl(String prefix)
    

Method Summary
public  voidaddActionConfig(ActionConfig config)
    

Ad d a new ActionConfig instance to the set associated with this module.
public  voidaddExceptionConfig(ExceptionConfig config)
    

Add a new ExceptionConfig instance to the set associated with this module.

public  voidaddFormBeanConfig(FormBeanConfig config)
    

Add a new FormBeanConfig instance to the set associated with this module.

public  voidaddForwardConfig(ForwardConfig config)
    

Add a new ForwardConfig instance to the set of global forwards associated with this module.

public  voidaddMessageResourcesConfig(MessageResourcesConfig config)
    

Add a new MessageResourcesConfig instance to the set associated with this module.

public  voidaddPlugInConfig(PlugInConfig plugInConfig)
    

Add a newly configured org.apache.struts.config.PlugInConfig instance to the set of plug-in Actions for this module.

public  ActionConfigfindActionConfig(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.

public  ActionConfigfindActionConfigId(String actionId)
    
public  ActionConfig[]findActionConfigs()
    

Return the action configurations for this module.

public  ExceptionConfigfindException(Class type)
    

Find and return the ExceptionConfig instance defining how Exceptions of the specified type should be handled.

public  ExceptionConfigfindExceptionConfig(String type)
    

Return the exception configuration for the specified type, if any; otherwise return null.

public  ExceptionConfig[]findExceptionConfigs()
    

Return the exception configurations for this module.

public  FormBeanConfigfindFormBeanConfig(String name)
    

Return the form bean configuration for the specified key, if any; otherwise return null.

public  FormBeanConfig[]findFormBeanConfigs()
    

Return the form bean configurations for this module.

public  ForwardConfigfindForwardConfig(String name)
    

Return the forward configuration for the specified key, if any; otherwise return null.

public  ForwardConfig[]findForwardConfigs()
    

Return the form bean configurations for this module.

public  MessageResourcesConfigfindMessageResourcesConfig(String key)
    

Return the message resources configuration for the specified key, if any; otherwise return null.

public  MessageResourcesConfig[]findMessageResourcesConfigs()
    

Return the message resources configurations for this module.

public  PlugInConfig[]findPlugInConfigs()
    

Return the configured plug-in actions for this module.

public  voidfreeze()
    

Freeze the configuration of this module.

public  StringgetActionFormBeanClass()
    
public  StringgetActionForwardClass()
    

The default class name to be used when creating action forward instances.

public  StringgetActionMappingClass()
    
public  booleangetConfigured()
    

Has this module been completely configured yet.
public  ControllerConfiggetControllerConfig()
    
public  StringgetPrefix()
    

The prefix of the context-relative portion of the request URI, used to select this configuration versus others supported by the controller servlet.

public  voidremoveActionConfig(ActionConfig config)
    

Remove the specified action configuration instance.

public  voidremoveExceptionConfig(ExceptionConfig config)
    

Remove the specified exception configuration instance.

public  voidremoveFormBeanConfig(FormBeanConfig config)
    

Remove the specified form bean configuration instance.

public  voidremoveForwardConfig(ForwardConfig config)
    

Remove the specified forward configuration instance.

public  voidremoveMessageResourcesConfig(MessageResourcesConfig config)
    

Remove the specified message resources configuration instance.

public  voidsetActionFormBeanClass(String actionFormBeanClass)
    
public  voidsetActionForwardClass(String actionForwardClass)
    

The default class name to be used when creating action forward instances.

public  voidsetActionMappingClass(String actionMappingClass)
    

The default class name to be used when creating action mapping instances.

public  voidsetControllerConfig(ControllerConfig cc)
    
public  voidsetPrefix(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.


Field Detail
actionConfigIds
protected HashMap actionConfigIds(Code)

The set of action configuration for this module, if any, keyed by the actionId property.




actionConfigList
protected List actionConfigList(Code)

The set of action configurations for this module, if any, listed in the order in which they are added.




actionConfigs
protected HashMap actionConfigs(Code)

The set of action configurations for this module, if any, keyed by the path property.




actionFormBeanClass
protected String actionFormBeanClass(Code)

The default class name to be used when creating action form bean instances.




actionForwardClass
protected String actionForwardClass(Code)
The default class name to be used when creating action forward instances.



actionMappingClass
protected String actionMappingClass(Code)
The default class name to be used when creating action mapping instances.



controllerConfig
protected ControllerConfig controllerConfig(Code)

The controller configuration object for this module.




exceptions
protected HashMap exceptions(Code)

The set of exception handling configurations for this module, if any, keyed by the type property.




formBeans
protected HashMap formBeans(Code)

The set of form bean configurations for this module, if any, keyed by the name property.




forwards
protected HashMap forwards(Code)

The set of global forward configurations for this module, if any, keyed by the name property.




log
protected static Log log(Code)

Commons Logging instance.




matcher
protected ActionConfigMatcher matcher(Code)

Matches action config paths against compiled wildcard patterns




messageResources
protected HashMap messageResources(Code)

The set of message resources configurations for this module, if any, keyed by the key property.




plugIns
protected ArrayList plugIns(Code)

The set of configured plug-in Actions for this module, if any, in the order they were declared and configured.




prefix
protected String prefix(Code)

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.





Constructor Detail
ModuleConfigImpl
public ModuleConfigImpl()(Code)

Constructor for ModuleConfigImpl. Assumes default configuration.


since:
   Struts 1.2.8



ModuleConfigImpl
public ModuleConfigImpl(String prefix)(Code)

Construct an ModuleConfigImpl object according to the specified parameter values.


Parameters:
  prefix - Context-relative URI prefix for this module




Method Detail
addActionConfig
public void addActionConfig(ActionConfig config)(Code)

Ad d a new ActionConfig instance to the set associated with this module.


Parameters:
  config - The new configuration instance to be added
throws:
  IllegalStateException - if this module configuration has beenfrozen



addExceptionConfig
public void addExceptionConfig(ExceptionConfig config)(Code)

Add a new ExceptionConfig instance to the set associated with this module.


Parameters:
  config - The new configuration instance to be added
throws:
  IllegalStateException - if this module configuration has beenfrozen



addFormBeanConfig
public void addFormBeanConfig(FormBeanConfig config)(Code)

Add a new FormBeanConfig instance to the set associated with this module.


Parameters:
  config - The new configuration instance to be added
throws:
  IllegalStateException - if this module configuration has beenfrozen



addForwardConfig
public void addForwardConfig(ForwardConfig config)(Code)

Add a new ForwardConfig instance to the set of global forwards associated with this module.


Parameters:
  config - The new configuration instance to be added
throws:
  IllegalStateException - if this module configuration has beenfrozen



addMessageResourcesConfig
public void addMessageResourcesConfig(MessageResourcesConfig config)(Code)

Add a new MessageResourcesConfig instance to the set associated with this module.


Parameters:
  config - The new configuration instance to be added
throws:
  IllegalStateException - if this module configuration has beenfrozen



addPlugInConfig
public void addPlugInConfig(PlugInConfig plugInConfig)(Code)

Add a newly configured org.apache.struts.config.PlugInConfig instance to the set of plug-in Actions for this module.


Parameters:
  plugInConfig - The new configuration instance to be added



findActionConfig
public ActionConfig findActionConfig(String path)(Code)

Return the action configuration for the specified path, first looking a direct match, then if none found, a wildcard pattern match; otherwise return null.


Parameters:
  path - Path of the action configuration to return



findActionConfigId
public ActionConfig findActionConfigId(String actionId)(Code)

Returns the action configuration for the specifed action action identifier.


Parameters:
  actionId - the action identifier the action config if found; otherwise null
See Also:   ActionConfig.getActionId
since:
   Struts 1.3.6



findActionConfigs
public ActionConfig[] findActionConfigs()(Code)

Return the action configurations for this module. If there are none, a zero-length array is returned.




findException
public ExceptionConfig findException(Class type)(Code)

Find and return the ExceptionConfig instance defining how Exceptions of the specified type should be handled.

In original Struts usage, this was only available in ActionConfig, but there are cases when an exception could be thrown before an ActionConfig has been identified, where global exception handlers may still be pertinent.

TODO: Look for a way to share this logic with ActionConfig, although there are subtle differences, and it certainly doesn't seem like it should be done with inheritance.


Parameters:
  type - Exception class for which to find a handler
since:
   Struts 1.3.0



findExceptionConfig
public ExceptionConfig findExceptionConfig(String type)(Code)

Return the exception configuration for the specified type, if any; otherwise return null.


Parameters:
  type - Exception class name to find a configuration for



findExceptionConfigs
public ExceptionConfig[] findExceptionConfigs()(Code)

Return the exception configurations for this module. If there are none, a zero-length array is returned.




findFormBeanConfig
public FormBeanConfig findFormBeanConfig(String name)(Code)

Return the form bean configuration for the specified key, if any; otherwise return null.


Parameters:
  name - Name of the form bean configuration to return



findFormBeanConfigs
public FormBeanConfig[] findFormBeanConfigs()(Code)

Return the form bean configurations for this module. If there are none, a zero-length array is returned.




findForwardConfig
public ForwardConfig findForwardConfig(String name)(Code)

Return the forward configuration for the specified key, if any; otherwise return null.


Parameters:
  name - Name of the forward configuration to return



findForwardConfigs
public ForwardConfig[] findForwardConfigs()(Code)

Return the form bean configurations for this module. If there are none, a zero-length array is returned.




findMessageResourcesConfig
public MessageResourcesConfig findMessageResourcesConfig(String key)(Code)

Return the message resources configuration for the specified key, if any; otherwise return null.


Parameters:
  key - Key of the data source configuration to return



findMessageResourcesConfigs
public MessageResourcesConfig[] findMessageResourcesConfigs()(Code)

Return the message resources configurations for this module. If there are none, a zero-length array is returned.




findPlugInConfigs
public PlugInConfig[] findPlugInConfigs()(Code)

Return the configured plug-in actions for this module. If there are none, a zero-length array is returned.




freeze
public void freeze()(Code)

Freeze the configuration of this module. After this method returns, any attempt to modify the configuration will return an IllegalStateException.




getActionFormBeanClass
public String getActionFormBeanClass()(Code)

The default class name to be used when creating action form bean instances.




getActionForwardClass
public String getActionForwardClass()(Code)

The default class name to be used when creating action forward instances.




getActionMappingClass
public String getActionMappingClass()(Code)

The default class name to be used when creating action mapping instances.




getConfigured
public boolean getConfigured()(Code)

Has this module been completely configured yet. Once this flag has been set, any attempt to modify the configuration will return an IllegalStateException.




getControllerConfig
public ControllerConfig getControllerConfig()(Code)

The controller configuration object for this module.




getPrefix
public String getPrefix()(Code)

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.




removeActionConfig
public void removeActionConfig(ActionConfig config)(Code)

Remove the specified action configuration instance.


Parameters:
  config - ActionConfig instance to be removed
throws:
  IllegalStateException - if this module configuration has beenfrozen



removeExceptionConfig
public void removeExceptionConfig(ExceptionConfig config)(Code)

Remove the specified exception configuration instance.


Parameters:
  config - ActionConfig instance to be removed
throws:
  IllegalStateException - if this module configuration has beenfrozen



removeFormBeanConfig
public void removeFormBeanConfig(FormBeanConfig config)(Code)

Remove the specified form bean configuration instance.


Parameters:
  config - FormBeanConfig instance to be removed
throws:
  IllegalStateException - if this module configuration has beenfrozen



removeForwardConfig
public void removeForwardConfig(ForwardConfig config)(Code)

Remove the specified forward configuration instance.


Parameters:
  config - ForwardConfig instance to be removed
throws:
  IllegalStateException - if this module configuration has beenfrozen



removeMessageResourcesConfig
public void removeMessageResourcesConfig(MessageResourcesConfig config)(Code)

Remove the specified message resources configuration instance.


Parameters:
  config - MessageResourcesConfig instance to be removed
throws:
  IllegalStateException - if this module configuration has beenfrozen



setActionFormBeanClass
public void setActionFormBeanClass(String actionFormBeanClass)(Code)

The default class name to be used when creating action form bean instances.


Parameters:
  actionFormBeanClass - default class name to be used when creatingaction form bean instances.



setActionForwardClass
public void setActionForwardClass(String actionForwardClass)(Code)

The default class name to be used when creating action forward instances.


Parameters:
  actionForwardClass - default class name to be used when creatingaction forward instances.



setActionMappingClass
public void setActionMappingClass(String actionMappingClass)(Code)

The default class name to be used when creating action mapping instances.


Parameters:
  actionMappingClass - default class name to be used when creatingaction mapping instances.



setControllerConfig
public void setControllerConfig(ControllerConfig cc)(Code)

The controller configuration object for this module.


Parameters:
  cc - The controller configuration object for this module.



setPrefix
public void setPrefix(String prefix)(Code)

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.




Fields inherited from org.apache.struts.config.BaseConfig
protected boolean configured(Code)(Java Doc)

Methods inherited from org.apache.struts.config.BaseConfig
protected Properties copyProperties()(Code)(Java Doc)
public void freeze()(Code)(Java Doc)
protected Properties getProperties()(Code)(Java Doc)
public String getProperty(String key)(Code)(Java Doc)
protected void inheritProperties(BaseConfig baseConfig)(Code)(Java Doc)
protected void setProperties(Properties properties)(Code)(Java Doc)
public void setProperty(String key, String value)(Code)(Java Doc)
public void throwIfConfigured()(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.