dmkarr 2002/11/08 20:04:11 Modified: src/share/org/apache/struts/action DynaActionFormClass.java src/share/org/apache/struts/tiles DefinitionsFactoryConfig.java src/share/org/apache/struts/upload CommonsMultipartRequestHandler.java src/share/org/apache/struts/util MessageResources.java Log: Fixed javadoc minor issues. Revision Changes Path 1.9 +5 -5 jakarta-struts/src/share/org/apache/struts/action/DynaActionFormClass.java Index: DynaActionFormClass.java =================================================================== RCS file: /home/cvs/jakarta-struts/src/share/org/apache/struts/action/DynaActionFormClass.java,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- DynaActionFormClass.java 23 Jul 2002 01:02:51 -0000 1.8 +++ DynaActionFormClass.java 9 Nov 2002 04:04:11 -0000 1.9 @@ -349,7 +349,7 @@ /** * Return the implementation class we are using to construct new * instances, re-introspecting our {@link FormBeanConfig} if necessary - * (i.e. after being deserialized, since <code>beanClass</code> is + * (that is, after being deserialized, since <code>beanClass</code> is * marked transient. */ protected Class getBeanClass() { 1.4 +310 -308 jakarta-struts/src/share/org/apache/struts/tiles/DefinitionsFactoryConfig.java Index: DefinitionsFactoryConfig.java =================================================================== RCS file: /home/cvs/jakarta-struts/src/share/org/apache/struts/tiles/DefinitionsFactoryConfig.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- DefinitionsFactoryConfig.java 5 Nov 2002 14:15:53 -0000 1.3 +++ DefinitionsFactoryConfig.java 9 Nov 2002 04:04:11 -0000 1.4 @@ -82,321 +82,323 @@ public class DefinitionsFactoryConfig implements Serializable { - /** - * Fully qualfied 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 factoryClassname = "org.apache.struts.tiles.xmlDefinition.I18nFactorySet"; - - /** - * Debug level value. 0=no debug info >0 = debug info. - * @deprecated Use commons-logging mechanism. - */ - protected int debugLevel = 0; - - /** - * Debug level value used when parsing configuration file. - * . 0=no debug info >0 = debug info. - * @deprecated Use commons-logging mechanism. - */ - protected int parserDebugLevel = 0; - - /** - * Do we want the parser to validate configuration file ? - * Default value is true. - */ - protected boolean parserValidate = true; - /** Definition configuration file specofied by user */ - protected String definitionConfigFiles; - - /** Does the factory is module aware ? */ - protected boolean moduleAware = true; - - /** - * The name associated to this factory. - * <br> - * With Struts > 1.1b3, this name is the module name to which this factory - * belong. It is set by the system. - * <br> - * In other versions, this properties is not used. - */ - protected String factoryName; - - /** Alternate name for parser debug details properties in configuration file */ - public static final String PARSER_DETAILS_PARAMETER_NAME = "definitions-parser-details"; - /** Alternate name for parser validate properties in configuration file */ - public static final String PARSER_VALIDATE_PARAMETER_NAME = "definitions-parser-validate"; - /** Alternate name for factory classname properties in configuration file */ - public static final String FACTORY_CLASSNAME_PARAMETER_NAME = "definitions-factory-class"; - /** Alternate name for definition files properties in configuration file */ - public static final String DEFINITIONS_CONFIG_PARAMETER_NAME = "definitions-config"; - /** Alternate name for definition debug details properties in configuration file */ - public static final String TILES_DETAILS_PARAMETER_NAME = "definitions-debug"; - - /** - * Map of extra attribute available. - */ - private Map extraAttributes = new HashMap(); - - /** - * Default constructor. - */ - public DefinitionsFactoryConfig() - { - - } - - /** - * Constructor. - * Create configuration object, and initialize it with parameters from Map. - * Parameters corresponding to an attribute are filtered and stored in appropriate - * attribute. - * @param initParameters - */ - public DefinitionsFactoryConfig(Map initParameters) - { + /** + * 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 factoryClassname = "org.apache.struts.tiles.xmlDefinition.I18nFactorySet"; + + /** + * Debug level value. 0=no debug info >0 = debug info. + * @deprecated Use commons-logging mechanism. + */ + protected int debugLevel = 0; + + /** + * Debug level value used when parsing configuration file. + * 0=no debug info; >0 = debug info. + * @deprecated Use commons-logging mechanism. + */ + protected int parserDebugLevel = 0; + + /** + * Specifies whether the parser will validate configuration files. + * Default value is true. + */ + protected boolean parserValidate = true; + /** Definition configuration file specified by user */ + protected String definitionConfigFiles; + + /** + * Specifies whether the factory is "module-aware". + */ + protected boolean moduleAware = true; + + /** + * The name associated to this factory. + * <br> + * With Struts > 1.1b3, this name is the module name to which this factory + * belong. It is set by the system. + * <br> + * In other versions, this properties is not used. + */ + protected String factoryName; + + /** Alternate name for parser debug details properties in configuration file */ + public static final String PARSER_DETAILS_PARAMETER_NAME = "definitions-parser-details"; + /** Alternate name for parser validate properties in configuration file */ + public static final String PARSER_VALIDATE_PARAMETER_NAME = "definitions-parser-validate"; + /** Alternate name for factory classname properties in configuration file */ + public static final String FACTORY_CLASSNAME_PARAMETER_NAME = "definitions-factory-class"; + /** Alternate name for definition files properties in configuration file */ + public static final String DEFINITIONS_CONFIG_PARAMETER_NAME = "definitions-config"; + /** Alternate name for definition debug details properties in configuration file */ + public static final String TILES_DETAILS_PARAMETER_NAME = "definitions-debug"; + + /** + * Map of extra attribute available. + */ + private Map extraAttributes = new HashMap(); + + /** + * Default constructor. + */ + public DefinitionsFactoryConfig() + { - } + } + + /** + * Constructor. + * Create configuration object, and initialize it with parameters from Map. + * Parameters corresponding to an attribute are filtered and stored in appropriate + * attribute. + * @param initParameters + */ + public DefinitionsFactoryConfig(Map initParameters) + { + + } /** * Get the module aware flag. * true: user want a single factory instance * false: user want multiple factory instance (one per module with Struts) */ - public boolean isModuleAware() - { - return moduleAware; - } + public boolean isModuleAware() + { + return moduleAware; + } /** * Set the module aware flag. * true: user want a single factory instance * false: user want multiple factory instance (one per module with Struts) * @param singleFactoryInstance */ - public void setModuleAware(boolean moduleAware) - { - this.moduleAware = moduleAware; - } - - /** - * Access method for the factoryClassname property. - * - * @return the current value of the factoryClassname property - */ - public String getFactoryClassname() - { - return factoryClassname; - } - - /** - * Sets the value of the factoryClassname property. - * - * @param aFactoryClassname the new value of the factoryClassname property - */ - public void setFactoryClassname(String aFactoryClassname) - { - factoryClassname = aFactoryClassname; - } - - /** - * Access method for the debugLevel property. - * - * @return the current value of the debugLevel property - */ - public int getDebugLevel() - { - return debugLevel; - } - - /** - * Sets the value of the debugLevel property. - * - * @param aDebugLevel the new value of the debugLevel property - */ - public void setDebugLevel(int aDebugLevel) - { - debugLevel = aDebugLevel; - } - - /** - * Access method for the parserDebugLevel property. - * - * @return the current value of the parserDebugLevel property - */ - public int getParserDebugLevel() - { - return parserDebugLevel; - } - - /** - * Sets the value of the parserDebugLevel property. - * - * @param aParserDebugLevel the new value of the parserDebugLevel property - */ - public void setParserDebugLevel(int aParserDebugLevel) - { - parserDebugLevel = aParserDebugLevel; - } - - /** - * Determines if the parserValidate property is true. - * - * @return <code>true<code> if the parserValidate property is true - */ - public boolean getParserValidate() - { - return parserValidate; - } - - /** - * Sets the value of the parserValidate property. - * - * @param aParserValidate the new value of the parserValidate property - */ - public void setParserValidate(boolean aParserValidate) - { - parserValidate = aParserValidate; - } - - /** - * Access method for the definitionConfigFiles property. - * - * @return the current value of the definitionConfigFiles property - */ - public String getDefinitionConfigFiles() - { - return definitionConfigFiles; - } - - /** - * Sets the value of the definitionConfigFiles property. - * - * @param aDefinitionConfigFiles the new value of the definitionConfigFiles property - */ - public void setDefinitionConfigFiles(String aDefinitionConfigFiles) - { - definitionConfigFiles = aDefinitionConfigFiles; - } - - /** - * Set a new extra attribute value. - * @param name Name of the attribute. - * @param value Value of the attribute. - */ - public void setAttribute(String name, Object value) - { - extraAttributes.put(name, value); - } - - /** - * Get extra attribute value. - * @param name Name of the attribute. - * @return Value of the attribute, or null if not found. - */ - public Object getAttribute(String name) - { - return extraAttributes.get(name); - } - - /** - * Get extra attributes as a Map. - * @return Map A Map containing attribute name - value pair. - */ - public Map getAttributes() - { - Map map = new HashMap(extraAttributes); - // Add property attributes using old names - /* - map.put(DEFINITIONS_CONFIG_PARAMETER_NAME, getDefinitionConfigFiles()); - map.put(TILES_DETAILS_PARAMETER_NAME, Integer.toString(getDebugLevel()) ); - map.put(PARSER_DETAILS_PARAMETER_NAME, Integer.toString(getParserDebugLevel()) ); - map.put(PARSER_VALIDATE_PARAMETER_NAME, new Boolean(getParserValidate()).toString() ); - - if( ! "org.apache.struts.tiles.xmlDefinition.I18nFactorySet".equals(getFactoryClassname()) ) - map.put(FACTORY_CLASSNAME_PARAMETER_NAME, getFactoryClassname()); - */ - return map; - } - - /** - * 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. - * <p> - * Properties keys are scanned for old property names, and linked to new name - * if necessary. This modify the properties map. - * <p> - * 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. - * <p> - * <strong>NOTE</strong>: It is contrary to the JavaBeans Specification - * to have more than one setter method (with different argument - * signatures) for the same property. - * - * @param properties Map keyed by property name, with the - * corresponding (String or String[]) value(s) to be set - * - * @exception IllegalAccessException if the caller does not have - * access to the property accessor method - * @exception InvocationTargetException if the property accessor method - * throws an exception - * @see org.apache.commons.beanutils.BeanUtils - */ - public void populate( Map properties) - throws java.lang.IllegalAccessException,java.lang.reflect.InvocationTargetException - { - // link old parameter names for backward compatibility - linkOldPropertyNames(properties); - BeanUtils.populate( this, properties); - } - - /** - * Link old property names to new property names. - * This modify the map. - * @param properties Map keyed by property name, with the - * corresponding (String or String[]) value(s) to be set - * - */ - static public void linkOldPropertyNames( Map properties) - { - Set entries = properties.entrySet(); - Map toAdd = new HashMap(); - Iterator i = entries.iterator(); - while( i.hasNext() ) - { - Map.Entry entry = (Map.Entry)i.next(); - if(DEFINITIONS_CONFIG_PARAMETER_NAME.equals(entry.getKey())) - toAdd.put( "definitionConfigFiles", entry.getValue()); - else if(FACTORY_CLASSNAME_PARAMETER_NAME.equals(entry.getKey())) - toAdd.put( "factoryClassname", entry.getValue()); - else if(PARSER_DETAILS_PARAMETER_NAME.equals(entry.getKey())) - toAdd.put( "parserDebugLevel", entry.getValue()); - else if(PARSER_VALIDATE_PARAMETER_NAME.equals(entry.getKey())) - toAdd.put( "parserValidate", entry.getValue()); - else if(TILES_DETAILS_PARAMETER_NAME.equals(entry.getKey())) - toAdd.put( "debugLevel", entry.getValue()); - } // end loop - if( toAdd.size() > 0 ) - properties.putAll( toAdd ); - } - - /** - * Get the factory name. - */ - public String getFactoryName() - { - return factoryName; - } - /** - * Set the factory name. - */ - public void setFactoryName(String factoryName) - { - this.factoryName = factoryName; - } + public void setModuleAware(boolean moduleAware) + { + this.moduleAware = moduleAware; + } + + /** + * Access method for the factoryClassname property. + * + * @return the current value of the factoryClassname property + */ + public String getFactoryClassname() + { + return factoryClassname; + } + + /** + * Sets the value of the factoryClassname property. + * + * @param aFactoryClassname the new value of the factoryClassname property + */ + public void setFactoryClassname(String aFactoryClassname) + { + factoryClassname = aFactoryClassname; + } + + /** + * Access method for the debugLevel property. + * + * @return the current value of the debugLevel property + */ + public int getDebugLevel() + { + return debugLevel; + } + + /** + * Sets the value of the debugLevel property. + * + * @param aDebugLevel the new value of the debugLevel property + */ + public void setDebugLevel(int aDebugLevel) + { + debugLevel = aDebugLevel; + } + + /** + * Access method for the parserDebugLevel property. + * + * @return the current value of the parserDebugLevel property + */ + public int getParserDebugLevel() + { + return parserDebugLevel; + } + + /** + * Sets the value of the parserDebugLevel property. + * + * @param aParserDebugLevel the new value of the parserDebugLevel property + */ + public void setParserDebugLevel(int aParserDebugLevel) + { + parserDebugLevel = aParserDebugLevel; + } + + /** + * Determines if the parserValidate property is true. + * + * @return <code>true<code> if the parserValidate property is true + */ + public boolean getParserValidate() + { + return parserValidate; + } + + /** + * Sets the value of the parserValidate property. + * + * @param aParserValidate the new value of the parserValidate property + */ + public void setParserValidate(boolean aParserValidate) + { + parserValidate = aParserValidate; + } + + /** + * Access method for the definitionConfigFiles property. + * + * @return the current value of the definitionConfigFiles property + */ + public String getDefinitionConfigFiles() + { + return definitionConfigFiles; + } + + /** + * Sets the value of the definitionConfigFiles property. + * + * @param aDefinitionConfigFiles the new value of the definitionConfigFiles property + */ + public void setDefinitionConfigFiles(String aDefinitionConfigFiles) + { + definitionConfigFiles = aDefinitionConfigFiles; + } + + /** + * Set a new extra attribute value. + * @param name Name of the attribute. + * @param value Value of the attribute. + */ + public void setAttribute(String name, Object value) + { + extraAttributes.put(name, value); + } + + /** + * Get extra attribute value. + * @param name Name of the attribute. + * @return Value of the attribute, or null if not found. + */ + public Object getAttribute(String name) + { + return extraAttributes.get(name); + } + + /** + * Get extra attributes as a Map. + * @return Map A Map containing attribute name - value pair. + */ + public Map getAttributes() + { + Map map = new HashMap(extraAttributes); + // Add property attributes using old names + /* + map.put(DEFINITIONS_CONFIG_PARAMETER_NAME, getDefinitionConfigFiles()); + map.put(TILES_DETAILS_PARAMETER_NAME, Integer.toString(getDebugLevel()) ); + map.put(PARSER_DETAILS_PARAMETER_NAME, Integer.toString(getParserDebugLevel()) ); + map.put(PARSER_VALIDATE_PARAMETER_NAME, new Boolean(getParserValidate()).toString() ); + + if( ! "org.apache.struts.tiles.xmlDefinition.I18nFactorySet".equals(getFactoryClassname()) ) + map.put(FACTORY_CLASSNAME_PARAMETER_NAME, getFactoryClassname()); + */ + return map; + } + + /** + * 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. + * <p> + * Properties keys are scanned for old property names, and linked to new name + * if necessary. This modify the properties map. + * <p> + * 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. + * <p> + * <strong>NOTE</strong>: It is contrary to the JavaBeans Specification + * to have more than one setter method (with different argument + * signatures) for the same property. + * + * @param properties Map keyed by property name, with the + * corresponding (String or String[]) value(s) to be set + * + * @exception IllegalAccessException if the caller does not have + * access to the property accessor method + * @exception InvocationTargetException if the property accessor method + * throws an exception + * @see org.apache.commons.beanutils.BeanUtils + */ + public void populate( Map properties) + throws java.lang.IllegalAccessException,java.lang.reflect.InvocationTargetException + { + // link old parameter names for backward compatibility + linkOldPropertyNames(properties); + BeanUtils.populate( this, properties); + } + + /** + * Link old property names to new property names. + * This modify the map. + * @param properties Map keyed by property name, with the + * corresponding (String or String[]) value(s) to be set + * + */ + static public void linkOldPropertyNames( Map properties) + { + Set entries = properties.entrySet(); + Map toAdd = new HashMap(); + Iterator i = entries.iterator(); + while( i.hasNext() ) + { + Map.Entry entry = (Map.Entry)i.next(); + if(DEFINITIONS_CONFIG_PARAMETER_NAME.equals(entry.getKey())) + toAdd.put( "definitionConfigFiles", entry.getValue()); + else if(FACTORY_CLASSNAME_PARAMETER_NAME.equals(entry.getKey())) + toAdd.put( "factoryClassname", entry.getValue()); + else if(PARSER_DETAILS_PARAMETER_NAME.equals(entry.getKey())) + toAdd.put( "parserDebugLevel", entry.getValue()); + else if(PARSER_VALIDATE_PARAMETER_NAME.equals(entry.getKey())) + toAdd.put( "parserValidate", entry.getValue()); + else if(TILES_DETAILS_PARAMETER_NAME.equals(entry.getKey())) + toAdd.put( "debugLevel", entry.getValue()); + } // end loop + if( toAdd.size() > 0 ) + properties.putAll( toAdd ); + } + + /** + * Get the factory name. + */ + public String getFactoryName() + { + return factoryName; + } + /** + * Set the factory name. + */ + public void setFactoryName(String factoryName) + { + this.factoryName = factoryName; + } } 1.6 +6 -6 jakarta-struts/src/share/org/apache/struts/upload/CommonsMultipartRequestHandler.java Index: CommonsMultipartRequestHandler.java =================================================================== RCS file: /home/cvs/jakarta-struts/src/share/org/apache/struts/upload/CommonsMultipartRequestHandler.java,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- CommonsMultipartRequestHandler.java 8 Nov 2002 05:39:24 -0000 1.5 +++ CommonsMultipartRequestHandler.java 9 Nov 2002 04:04:11 -0000 1.6 @@ -259,7 +259,7 @@ /** - * Returns a hash table containing the text (i.e. non-file) request + * Returns a hash table containing the text (that is, non-file) request * parameters. * * @return The text request parameters. @@ -270,7 +270,7 @@ /** - * Returns a hash table containing the file (i.e. non-text) request + * Returns a hash table containing the file (that is, non-text) request * parameters. * * @return The file request parameters. 1.16 +5 -5 jakarta-struts/src/share/org/apache/struts/util/MessageResources.java Index: MessageResources.java =================================================================== RCS file: /home/cvs/jakarta-struts/src/share/org/apache/struts/util/MessageResources.java,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- MessageResources.java 17 Oct 2002 03:20:31 -0000 1.15 +++ MessageResources.java 9 Nov 2002 04:04:11 -0000 1.16 @@ -132,7 +132,7 @@ /** * The <code>MessageResourcesFactory</code> that created this instance. - * @return<code>MessageResourcesFactory</code> that created instance + * @return <code>MessageResourcesFactory</code> that created instance */ public MessageResourcesFactory getFactory() { return (this.factory);
-- To unsubscribe, e-mail: <mailto:struts-dev-unsubscribe@;jakarta.apache.org> For additional commands, e-mail: <mailto:struts-dev-help@;jakarta.apache.org>