Prev Class | Next Class | Frames | No Frames |
Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Object
org.apache.struts.tiles.DefinitionsFactoryConfig
public class DefinitionsFactoryConfig
extends java.lang.Object
implements Serializable
Field Summary | |
static String |
|
static String |
|
static String |
|
static String |
|
static String |
|
protected int |
|
protected String |
|
private Map |
|
protected String |
|
protected String |
|
protected boolean |
|
protected int |
|
protected boolean |
|
Constructor Summary | |
| |
|
Method Summary | |
Object |
|
Map |
|
int |
|
String |
|
String |
|
String |
|
int |
|
boolean |
|
boolean |
|
static void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
public static final String DEFINITIONS_CONFIG_PARAMETER_NAME
Alternate name for definition files properties in configuration file
public static final String FACTORY_CLASSNAME_PARAMETER_NAME
Alternate name for factory classname properties in configuration file
public static final String PARSER_DETAILS_PARAMETER_NAME
Alternate name for parser debug details properties in configuration file
public static final String PARSER_VALIDATE_PARAMETER_NAME
Alternate name for parser validate properties in configuration file
public static final String TILES_DETAILS_PARAMETER_NAME
Alternate name for definition debug details properties in configuration file
protected int debugLevel
Deprecated. Use commons-logging mechanism.
Debug level value. 0=no debug info >0 = debug info.
protected String definitionConfigFiles
Definition configuration file specified by user
private Map extraAttributes
Map of extra attribute available.
protected String factoryClassname
Fully qualified classname of the factory to create. If no classname is set, a default factory is created (of class "org.apache.struts.tiles.xmlDefinition.I18nFactorySet").
protected String factoryName
The name associated to this factory.
With Struts 1.1, this name is the module name to which this factory belong. It is set by the system.
In prior versions, this property is not used.
protected boolean moduleAware
Specifies whether the factory is "module-aware".
protected int parserDebugLevel
Deprecated. Use commons-logging mechanism.
Debug level value used when parsing configuration file. 0=no debug info; >0 = debug info.
protected boolean parserValidate
Specifies whether the parser will validate configuration files. Default value is true.
public DefinitionsFactoryConfig()
Default constructor.
public DefinitionsFactoryConfig(Map initParameters)
Constructor. Create configuration object, and initialize it with parameters from Map. Parameters corresponding to an attribute are filtered and stored in appropriate attribute.
- Parameters:
initParameters
- Map.
public Object getAttribute(String name)
Get value of an additional attribute.
- Parameters:
name
- Name of the attribute.
- Returns:
- Value of the attribute, or null if not found.
public Map getAttributes()
Get additional attributes as a Map.
- Returns:
- Map A Map containing attribute name - value pairs.
public int getDebugLevel()
Deprecated. Use commons-logging mechanism.
Get debug level.
- Returns:
- Debug level.
public String getDefinitionConfigFiles()
Get the definition config files.
- Returns:
- Defition config files.
public String getFactoryClassname()
Get the classname of the factory.
- Returns:
- Classname.
public String getFactoryName()
Get the factory name.
public int getParserDebugLevel()
Deprecated. Use commons-logging mechanism.
Get the debug level for the parser.
- Returns:
- Debug level.
public boolean getParserValidate()
Determines if the parser is validating.
- Returns:
true
when in validating mode.
public boolean isModuleAware()
Get the module aware flag.
- Returns:
true
: user wants a single factory instance,false
: user wants multiple factory instances (one per module with Struts)
public static void linkOldPropertyNames(Map properties)
Link old property names to new property names. This modifies the map.
- Parameters:
properties
- Map keyed by property name, with the corresponding (String or String[]) value(s) to be set.
public void populate(Map properties) throws java.lang.IllegalAccessException, java.lang.reflect.InvocationTargetException
Populate this config object from properties map, based on the specified name/value pairs. This method uses the populate() method from org.apache.commons.beanutils.BeanUtil. Properties keys are scanned for old property names, and linked to the new name if necessary. This modifies the properties map. The particular setter method to be called for each property is determined using the usual JavaBeans introspection mechanisms. Thus, you may identify custom setter methods using a BeanInfo class that is associated with the class of the bean itself. If no such BeanInfo class is available, the standard method name conversion ("set" plus the capitalized name of the property in question) is used. NOTE: It is contrary to the JavaBeans Specification to have more than one setter method (with different argument signatures) for the same property.
- Parameters:
properties
- Map keyed by property name, with the corresponding (String or String[]) value(s) to be set.
- See Also:
org.apache.commons.beanutils.BeanUtils
public void setAttribute(String name, Object value)
Set value of an additional attribute.
- Parameters:
name
- Name of the attribute.value
- Value of the attribute.
public void setDebugLevel(int aDebugLevel)
Deprecated. Use commons-logging mechanism.
Set debug level.
- Parameters:
aDebugLevel
- Debug level.
public void setDefinitionConfigFiles(String aDefinitionConfigFiles)
Set the definition config files.
- Parameters:
aDefinitionConfigFiles
- Definition config files.
public void setFactoryClassname(String aFactoryClassname)
Set the classname of the factory..
- Parameters:
aFactoryClassname
- Classname of the factory.
public void setFactoryName(String factoryName)
Set the factory name.
- Parameters:
factoryName
- Name of the factory.
public void setModuleAware(boolean moduleAware)
Set the module aware flag.
- Parameters:
moduleAware
-true
: user wants a single factory instance,false
: user wants multiple factory instances (one per module with Struts)
public void setParserDebugLevel(int aParserDebugLevel)
Deprecated. Use commons-logging mechanism.
Set the debug level for the parser.
- Parameters:
aParserDebugLevel
- Debug level.
public void setParserValidate(boolean aParserValidate)
Set the validating mode for the parser.
- Parameters:
aParserValidate
-true
for validation,false
otherwise