cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Berin Loritsch <blorit...@apache.org>
Subject Re: [C2] Recusive Sitemap Calling
Date Mon, 26 Feb 2001 20:29:05 GMT
Giacomo Pati wrote:
> 
> Berin Loritsch wrote:
> > I have added some code that makes recursive sitemap calling possible.
> > It consists of two phases:
> >
> > 1) All serverpages are directly accessible via the Roles.SERVERPAGES
> >    ComponentSelector.
> >
> > 2) When the ProgramGenerator creates the Root Sitemap, it places the
> >    sitemap via it's NormalizedName as well as the alias "sitemap".
> >
> > In order to get a request for the sitemap, you do this:
> > ----------------------------------------------------------------
> > ComponentSelector serverpages = (ComponentSelector)
> > manager.lookup(Roles.SERVERPAGES);
> >
> > Sitemap sitemap = (Sitemap) serverpages.lookup("sitemap");
> >
> > sitemap.process(....);
> > -----------------------------------------------------------------
> > You also have direct access to all SitemapComponents.  This makes
> > aggregation easier as you no longer are forced to go through the
> > sitemap.
> >
> > To get a generator, use Roles.GENERATORS and select the one by name.
> > To get a transformer, you do the same thing.
> 
> I'm not sure I understand this. Have you took into account that sitemaps can
> be organized hierarchically by using the map:mount elements?

The alias is for the _root_ sitemap only.  Any aditional map:mount done
inside the sitemap is handled just like going through the Cocoon
object's process() method.

Mime
View raw message