Return-Path: Delivered-To: apmail-jakarta-struts-user-archive@www.apache.org Received: (qmail 8012 invoked from network); 2 Feb 2004 17:37:32 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 2 Feb 2004 17:37:32 -0000 Received: (qmail 46319 invoked by uid 500); 2 Feb 2004 17:35:30 -0000 Delivered-To: apmail-jakarta-struts-user-archive@jakarta.apache.org Received: (qmail 46276 invoked by uid 500); 2 Feb 2004 17:35:30 -0000 Mailing-List: contact struts-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Struts Users Mailing List" Reply-To: "Struts Users Mailing List" Delivered-To: mailing list struts-user@jakarta.apache.org Received: (qmail 46193 invoked from network); 2 Feb 2004 17:35:29 -0000 Received: from unknown (HELO mailout.ntsource.com) (208.223.150.20) by daedalus.apache.org with SMTP; 2 Feb 2004 17:35:29 -0000 Received: from mpb (office.ntsource.com [208.223.150.143]) by mailout.ntsource.com (8.11.6/8.11.6) with SMTP id i12HZNe08883 for ; Mon, 2 Feb 2004 11:35:23 -0600 Message-ID: <01eb01c3e9b2$ef9648c0$9501a8c0@mpb> From: "Matt Bathje" To: "Struts Users Mailing List" References: <20040202172314.19724.qmail@web60204.mail.yahoo.com> Subject: Re: Is there an INCLUDE feature that works with struts-config? Date: Mon, 2 Feb 2004 11:35:22 -0600 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N I think XML entities would do what he wants. What you do is, at the top of your struts-config.xml file, you define the entities you want to include: ]> Then, at each place you want to use the entity in your file, you include it as an entity using &entityName; (so for the above example: &actionMappings; and &formBeans;) So to include action mappings in your struts config that you have defined in another file, you would do: &actionMappings; In struts-config, the entity paths can be relative to your struts-config.xml file (usually /WEB-INF/), or hard coded paths to somewhere else on the file system. If you want to use entities in tiles-defs.xml or validation.xml, they must be hard coded paths (for now...I'm investigating this in my free time!!). Matt Bathje ----- Original Message ----- From: "Hubert Rabago" To: "Struts Users Mailing List" Sent: Monday, February 02, 2004 11:23 AM Subject: Re: Is there an INCLUDE feature that works with struts-config? > Probably not in the way you're thinking. > Struts allows you to specify more multiple config files for the same > app, so you can probably specify the app-specific config and the shared > config for each app. However, each of your apps will need to have copies of > the same shared XML. > If you're worried about duplication, you can have the shared config in > one location and have your build process copy it from there. > Just an idea. > > - Hubert > > --- "Anderson, James H [IT]" wrote: > > We will have many related Struts apps that require identical entries in > > struts-config, so I'm wondering if there's a way to define common sets of > > entries and then include them in the config file for each of the apps. > > > > Thanks, > > > > jim > > > > > > __________________________________ > Do you Yahoo!? > Yahoo! SiteBuilder - Free web site building tool. Try it! > http://webhosting.yahoo.com/ps/sb/ > > --------------------------------------------------------------------- > To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: struts-user-help@jakarta.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: struts-user-help@jakarta.apache.org