Return-Path: Delivered-To: apmail-xml-cocoon-dev-archive@xml.apache.org Received: (qmail 45495 invoked by uid 500); 27 Jun 2003 09:47:28 -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 45478 invoked from network); 27 Jun 2003 09:47:27 -0000 Received: from smtp8.wanadoo.fr (HELO mwinf0101.wanadoo.fr) (193.252.22.30) by daedalus.apache.org with SMTP; 27 Jun 2003 09:47:27 -0000 Received: from anyware-tech.com (unknown [81.51.192.62]) by mwinf0101.wanadoo.fr (SMTP Server) with ESMTP id 567B8C0000B2 for ; Fri, 27 Jun 2003 11:47:40 +0200 (CEST) Message-ID: <3EFC12BD.6070109@anyware-tech.com> Date: Fri, 27 Jun 2003 11:47:41 +0200 From: Sylvain Wallez Organization: Anyware Technologies User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3) Gecko/20030312 X-Accept-Language: fr, en-us, en MIME-Version: 1.0 To: cocoon-dev@xml.apache.org Subject: Re: [Flow] getComponent(id) implementation References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Carsten Ziegeler wrote: >Reinhard P�tz wrote: > > >>The Cocoon object of the FOM has the method >> >> Component getComponent(id) >> >>It should return any component but no sitemap components. This means we >>only return components defined in the roles file(s). How can we check if >>it is an "allowed" component? >> >>Any ideas? >> >> >I think the simplest solution is to use the correct component manager that holds only the components configured in roles/cocoon.xconf. This is the component manager of the o.a.c.Cocoon object. >Each sitemap as its own component manager for the sitemap component, they are linked in a hierarchy to the above mentioned one. > > Sorry if I missed something (was offline for several days -- lots of emails to read), but why is it necessary to make a distinction between sitemap components and other components ? What could be the possible use of e.g. a transformer in a flowscript ? I can't see one... So why build complicated fences to prevent something that is IMO doesn't even make sense ? Furthermore, and this is what triggered this answer, restricting getComponent() to the top-level CM goes strongly against the upcoming blocks and the fact that is nothing but a regular .xconf declaration. Sylvain -- Sylvain Wallez Anyware Technologies http://www.apache.org/~sylvain http://www.anyware-tech.com { XML, Java, Cocoon, OpenSource }*{ Training, Consulting, Projects } Orixo, the opensource XML business alliance - http://www.orixo.com