cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Hunsberger <peter.hunsber...@gmail.com>
Subject Re: RFC-2396 (Was: Re: [RT] composition vs. inheritance in blocks)
Date Mon, 04 Apr 2005 17:05:56 GMT
On Apr 4, 2005 11:16 AM, Daniel Fagerstrom <danielf@nada.kth.se> wrote:
> Peter Hunsberger wrote:
> 
> >On Apr 4, 2005 10:26 AM, Daniel Fagerstrom <danielf@nada.kth.se> wrote:
> >
> >
> >>Pier Fumagalli wrote:
> >>
> >>
> >>
> >>>On 31 Mar 2005, at 01:26, Stefano Mazzocchi wrote:
> >>>
> >>>
> >
> ><snip/>
> >
> >
> >
> >>As all URI discussions tend to provoke strong feelings for Stefano, it's
> >>best to say directly that this question is not important enough for me
> >>to fight about ;)
> >>
> >>But anyway, whether we go for an opaque custom protocol or base the
> >>block protocol on hierachial URIs we need to get into the specifics for
> >>the block URI scheme to be able to implement it.
> >>
> >>WDYT?
> >>
> >>
> >
> >He, he...  The more I look at this the more I wonder if maybe it
> >really isn't crazy to allow blocks to specify a resolver intercept
> >scheme.  Just lift the code directly out of mod-rewrite/mod-redirect
> >and let a block tell Cocoon what URI's have special concerns:
> >
> ><resolver>match spec</resolver>
> >
> >then you can go either way...
> >
> >
> I'm not following you, we already has source factories, so we can make
> our resolver as special as we want to. The question was rather if we
> should make them less special by using java.net.URI. Or do you have
> something else in mind?

Basically, the idea is to have a way for a block to say to treat a
given set of URI's in a special manner by performing a remapping on
them.  That way the incoming  request can be generic and transformed
into something block specific _before_ it hits the source factory. 
Eg, being able to say that

  http://site.com/foo/bar.css

ends up as:

   block:/foo/bar.css

where as:

    ../bar.css

gets passed through to Cocoon untouched, or vice versa, depending on
the needs of the block and the block user.  Perhaps this might be
better expressed as a "remap" directive than a "resolve" directive...

-- 
Peter Hunsberger

Mime
View raw message