forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nicola Ken Barozzi <nicola...@apache.org>
Subject Re: Data models (Re: Fixing menus)
Date Thu, 10 Apr 2003 13:22:16 GMT

Jeff Turner wrote, On 10/04/2003 12.56:
> On Wed, Apr 09, 2003 at 06:26:47PM +0200, Nicola Ken Barozzi wrote:
> 
>>Jeff Turner wrote, On 09/04/2003 18.18:
> 
> ...
> 
>>>OTOH, navigation.xml can precisely define a special menu for a directory,
>>>something site.xml can't do.
>>
>>So it seems that site.xml is a superset of navigation.xml, and that with 
>>a few additions it can be even better.
> 
> If we could allow a site.xml per directory which augments a central
> site.xml, then it would be a superset of what book.xml/navigation.xml
> offers.

Interesting.

But again, I miss the role of having the three.
If we have site.xml as you suggest, we could as well do without either. 
So as a user I would never use them, only the enhanced site.xml.

I still don't get what an explicit use of navigation.xml brings us in 
this case.

I would like as an alternative to allow *only* navigation.xml, because 
it brings us closer, but having also site.xml seems confusing. Hence 
maybe it's better not to support it explicitly.

Hmmm...

> ...
> 
>>Hmmm, ok, conceded. I put it in Gump's descriptor for my projects, but 
>>somewhere we decided not to go that way IIRC. What would you say about 
>>it now?
> 
> I think we should perhaps define a specification of what data we need for
> a Forrest site, and then figure out how to represent it as a:
>  - Gump descriptor
>  - Maven descriptor
>  - Custom XML for people who don't care about Gump/Maven
> 
> This abstract data model should include the directory layout of the site,
> currently captured in forrest.properties.
> 
> We could have a sitemap pipeline to convert external formats into a
> common internal format.
> 
> Haven't really thought this out though.

The concept seems nice,

>>>>and that's why I talk about putting in site.xml, that is where users
>>>>would maybe look how to config the site... just ramblings, leave it, I
>>>>have no real intention of changing it, and overmore I don't have clear
>>>>alternatives myself.
>>>
>>>That's where I'm at too: not sure how to fix it, leaving it until things
>>>become clearer.
>>
>>Yes.
>>
>>Personally I like having that info in Gump descriptors. I am writing a 
>>stylesheet that takes gump's merged descriptors and makes a site out of 
>>it, *also* with the infos like the ones above.
>>
>>Given that Maven can create a Gumpo descriptor from his already, I tend 
>>to think that we could use the Gump descriptor for it.
>>
>>Not that sure though, I might not be seeing nasty implications.
> 
> Sounds alright to me.

Ok then, let's see what goes into that descriptor.

 From skinconf.xml there are two kinds of tags IMHO: one tells us 
descriptove information about the *project* another about the *site*.

Project data:

   <searchsite-domain>www.krysalis.org</searchsite-domain>
   <searchsite-name>Krysalis</searchsite-name>

   <!-- mandatory project logo
        skin: forrest-site renders it at the top -->
   <project-name>Centipede</project-name>
   <project-url>http://www.krysalis.org/centipede//</project-url>
   <project-logo>images/project-logo.gif</project-logo>

   <!-- optional group logo
        skin: forrest-site renders it at the top-left corner -->
   <group-name>Krysalis</group-name>
   <group-url>http://www.krysalis.org/</group-url>
   <group-logo>images/group-logo.gif</group-logo>

   <!-- optional host logo (e.g. sourceforge logo)
        skin: forrest-site renders it at the bottom-left corner -->
   <host-url>http://sourceforge.net</host-url>
   <host-logo>http://sourceforge.net/sflogo.php?...</host-logo>

   <!-- The following are used to construct a copyright statement -->
   <year>2002-2003</year>
   <vendor>The Krysalis Community Project</vendor>

   <credits>
     <credit>
       <name>Built with Apache Forrest</name>
       <url>http://xml.apache.org/forrest/</url>
       <image>images/built-with-forrest-button.png</image>
       <width>88</width>
       <height>31</height>
     </credit>
   </credits>

IMHO these should go in the gump descriptor. I agree though that they 
should be extracted to a common format, merged with all datas, and fed 
that way into Forrest.

Anyway, here are the infos about the presentational aspects of the site:

   <!-- Do we want to disable the Google search box? -->
   <disable-search>false</disable-search>
   <!-- Do we want to disable the print link? -->
   <disable-print-link>false</disable-print-link>
   <!-- Do we want to disable the PDF link? -->
   <disable-pdf-link>false</disable-pdf-link>
   <!-- Do we want to disable the xml source link? -->
   <disable-xml-link>false</disable-xml-link>
   <!-- Do we want to disable w3c compliance links? -->
   <disable-compliance-links>false</disable-compliance-links>


   <!-- Some skins use this to form a 'breadcrumb trail' of links. If 
you don't
   want these, set the attributes to blank. The DTD purposefully 
requires them.
   -->
   <trail>
     <link1 name="krysalis at sf.net" 
href="http://www.sf.net/projects/krysalis/"/>
     <link2 name="krysalis" href="http://www.krysalis.org/"/>
     <link3 name="" href=""/>
   </trail>


These are not properly project properties, but may as well be put there, 
or with the new forrestproperties.

Then we have the forrest.properties, that are intimately tied to 
Forrest. They are not part of the project descriptor, as they cannot 
really be used by anything else, only Forrest.

These should remain, only that I would like them under the documentation 
dir. We would only need an extra tag in the descriptor that tells us 
where the base dir for Forrest is.

Since should not need forrest.properties for Ant but for Cocoon, we 
could as well:

1) read the Gump descriptor or equivalent and get the Forrest base
    dir
2) run Cocoon with that info
3) Cocoon uses its pipelines to gather info from the Gump profile
    (converting on the fly to skinconf for compatibility), and
    source locations from forrest.xml (the properties)

Are we getting nearer to a solution?

-- 
Nicola Ken Barozzi                   nicolaken@apache.org
             - verba volant, scripta manent -
    (discussions get forgotten, just code remains)
---------------------------------------------------------------------


Mime
View raw message