You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Chad Baker <CB...@mobius.com> on 2005/03/04 15:33:38 UTC
Re: DynaActionForm question / FW: ActionForms and Interfaces
This was posted a couple weeks back...
-----Original Message-----
From: Craig McClanahan [mailto:craigmcc@gmail.com]
Sent: Thursday, February 24, 2005 1:15 PM
To: Struts Users Mailing List; Matthew Hughes
Subject: Re: ActionForms and Interfaces
IIRC, there's some ongoing work to provide an "extends" capability in
DynaActionForm definitions. In the mean time, though, you can leverage the
fact that struts-config.xml is an XML document, and use XML entities to
encapsulate the common chunks. Consider:
<?xml version="1.0" ?>
<DOCTYPE struts-config ... [
<!ENTITY shared-props-1 "shared-properties-1.xml">
<!ENTITY shared-props-2 "shared-properties-2.xml">
]>
<struts-config>
...
<form-bean name="myBean" type="...">
<form-property>...unique property ...</form-property>
&shared-props-1;
&shared-props-2;
</form-bean>
<form-bean name="anotherBean" type="...">
<form-property>...unique property ...</form-property>
&shared-props-1;
</form-bean>
...
</struts-config>
Craig
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org