just a thought.
ie, not expose the "properties" object (as it is) by the
getProperties,setProperties methods. by my last viewing of the Config
classes, only ActionConfig uses "properties" and needs to change for
this - not much.
get/setProperties can be replaced by
void inheritProperties(childConfig) {
// for each "xx" property in (parent) class
// if childConfig.getProperty("xx") == null
// copy the arbitrary property
}
imho, i think this is a good way to do this, provides separation between
BaseConfig and its extending classes
is it worth submitting a patch?
riyaz
[EMAIL PROTECTED] wrote:
Author: hrabago
Date: Wed May 25 16:35:00 2005
New Revision: 178550
URL: http://svn.apache.org/viewcvs?rev=178550&view=rev
Log:
Copy arbitrary properties of inherited form bean properties, action mapping
forwards and exception handlers.
Modified:
struts/core/trunk/src/share/org/apache/struts/config/ActionConfig.java
struts/core/trunk/src/share/org/apache/struts/config/BaseConfig.java
struts/core/trunk/src/share/org/apache/struts/config/FormBeanConfig.java
struts/core/trunk/src/test/org/apache/struts/config/TestActionConfig.java
struts/core/trunk/src/test/org/apache/struts/config/TestFormBeanConfig.java
/**
* Return the entire set of properties configured for this object.
- * At this time, this only needs to be exposed
- * to support inheritance, so choosing a conservative access modifier ("protected").
+ * At this time, this only needs to be exposed to support inheritance,
+ * so choosing a conservative access modifier ("protected").
* @return
*/
protected Properties getProperties() {
@@ -123,6 +123,15 @@
}
+ /**
+ * Set the entire set of properties configured for this object.
+ * At this time, this only needs to be exposed to support inheritance,
+ * so choosing a conservative access modifier ("protected").
+ */
+ protected void setProperties(Properties properties) {
+ this.properties = properties;
+ }
+
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]