cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carsten Ziegeler" <cziege...@s-und-n.de>
Subject RE: [RT] Virtual Sitemap Components
Date Mon, 19 Jul 2004 12:56:18 GMT
Vadim Gritsenko wrote:
> 
> Carsten Ziegeler wrote:
> 
> >I'll try to summarize what we've got so far (as far as I 
> interpret this 
> >thread :) ):
> >
> >A VPC (virtual pipeline component) is like a macro (I didn't find a 
> >better term);
> >  
> >
> 
> I'm not sure I agree with this approach... I prefer to see 
> VPC opaque to the label processing, internals of the VPC 
> should not be considered when processing a view request.

Can you please explain what you mean by this?

> 
> Also, if you have virtual generator "x" defined, what will be 
> the result of serviceManager.lookup(Generator.ROLE).select("x")?
> 
A VPCGenerator object implementing the generator interface? I haven'T
thought about it very well, but I guess it's possible (if we only
allow pipeline components (G,T,S) for virtual components than this
is easy anyway; but as we allow more (Actions,Matchers,Selectors)
this might be slightly more difficult).


> <snip/>
> 
> 
> >The VPC from above resolves two sources (the src and the stylesheet).
> >The stylesheet should imho be resolved relative to the sitemap where 
> >the VPC is defined.
> >The src ("blah") should refer to a source that is relative to the 
> >sitemap of the Usage.
> >
> 
> That's what would I expect, and most users, I guess, too 
> would expect this behavior. How can we achive this?
> 
Oh, that's easy :) Before we pass the source to the virtual component,
we resolve it, creating an absolute path. The virtual components
get a source resolver that resolves relative to the sitemap of the VC.
Starting with 2.2 each sitemap has fortunately such a resolver :)

carsten


Mime
View raw message