Return-Path: Delivered-To: apmail-xml-cocoon-dev-archive@xml.apache.org Received: (qmail 77774 invoked by uid 500); 10 Apr 2001 09:23:05 -0000 Mailing-List: contact cocoon-dev-help@xml.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: cocoon-dev@xml.apache.org Delivered-To: mailing list cocoon-dev@xml.apache.org Received: (qmail 77763 invoked from network); 10 Apr 2001 09:23:04 -0000 To: cocoon-dev@xml.apache.org Subject: Re: [C2]: Avalon Component Configuration Message-ID: <986894586.3ad2d0faca205@mail.otego.com> Date: Tue, 10 Apr 2001 11:23:06 +0200 (CEST) From: Giacomo Pati References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit User-Agent: IMP/PHP IMAP webmail program 2.2.4 X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N Quoting Carsten Ziegeler : > Hi, > > I am trying to add new avalon components to the > cocoon.xconf (yes, for caching of course....) and am > now a little bit confused about the format. > > E.g. the parser has the following entries: > > > shorthand="parser" > default-class="org.apache.cocoon.components.parser.JaxpParser"/> > > Is the first one obsolete? I thought the second declaration adds > a component with the role name "parser". I'm not sure if the definition of the role is sufficent to define the component without the absolute minimum component definition (which in this case would be ). Berin, have you any comments on this handy? > For the URL Factory I found: > > class="org.apache.cocoon.components.url.ResourceURLFactory"/> > class="org.apache.cocoon.components.url.ContextURLFactory"/> > > > shorthand="url-factory" > default-class="org.apache.cocoon.components.url.URLFactoryImpl"/> > > Is the second one the definition for the role and the first one the > configuration for this role? Here the role states that a component specified as (because of the shorthand attribute) represented by class org.apache.cocoon.components.url.URLFactoryImpl will implement the working interface org.apache.cocoon.components.url.URLFactory. It might be possible to rewrite that using a ComponentSelector similar to the specification of the DataSource component. Generally the role element defines shorthands for component definition. Thus the complete definition for the URLFactory without a role definition will be: And yes, the elements are configurations for the url-factory only. Giacomo --------------------------------------------------------------------- To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org For additional commands, email: cocoon-dev-help@xml.apache.org