cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jean-Christophe Kermagoret <...@bluexml.org>
Subject Re: [RT] Resources Accessible Via Subsitemaps To Enable Better Re-Use
Date Fri, 05 May 2006 13:52:10 GMT
Hello,
you could use an entity to define/store your resource where you want.

That way, you could use it wherever you are.

Jean-Christophe

Adrien Guillon wrote:
>    Hello All,
> 
>    I have hit a stumbling block with Cocoon.  Basically, I have discovered on 
> past mailing list discussions, that resources in a sitemap are not accessible 
> by their mounted children sitemaps.  This presents a major obstacle for me.
> 
>    I understand that I can use the file generator with a call to cocoon://, 
> and even access an internal pipeline to keep things somewhat more secure and 
> separate concerns.  However, the fragments I am re-using do not contain a 
> generator or a serializer.  Let me explain...
> 
>    Basically, I frequently make a call to the SQL transformer to fetch some 
> information.  The result set is in an Apache SQL namespace, which is not what 
> I want.  I then apply a generic stylesheet to the result set from the SQL 
> transformer, to change the namespace to an internal namespace which reflects 
> what this result embodies (there is more to it than just that, I'm not just 
> changing the namespace, but the semantics of the result set too).  This helps 
> me not make mistakes, because I can say to myself "AHA! This is such and such 
> a result set, and so doesn't make sense here"... I also have other resources 
> that will be added as time goes on, and I can think of uses for them :-)
> 
>    I have put this into a resource, so that with a few parameters I can 
> perform the query (based off whatever XML is in the pipeline, and with a 
> parameter specifying which datasource to use... e.g. test database or 
> production)... another parameter specifies the namespace of the document.
> 
>    To my dismay, I cannot globally access the resources from the sub sitemaps.  
> This severely limits my usage of Cocoon... I either have to find a way to 
> "make it work" or come up with a creative solution.  However, I have 
> frequently felt restricted in working with cocoon lately... I'm not putting 
> down Cocoon in any way, just learning the Cocoon way takes some time :-)
> 
>    What is the official design reason for resources not being accessible by 
> child site maps ?
> 
>    Any suggestions would be greatly appreciated!
> 
>    AJ


-- 

BlueXML
Jean-Christophe Kermagoret
Directeur associƩ
jck@bluexml.org


Mime
View raw message