Jann Forrer wrote:
On Tue, 20 Sep 2005, Andreas Hartmann wrote:
Josias Thoeny wrote:
Hi,
In Lenya trunk, the SiteManager is an abstraction of the SiteTree, i.e.
Lenya should not directly use the SiteTree, but only the
SiteManager/SiteStructure.
Is that correct?
But then, how can sitetree attributes be handled?
Should the SiteManager (or the SiteStructure?) have methods to get/set
attributes like e.g. visibleInNav?
BTW, the label is also set in using the SiteManager
I was also thinking about the visibleinnav attribute today and i think
if probably make sense to use a "node interface".
Can't we use the interface o.a.l.cms.site.tree.SiteTree.java for
attributes which are special for pages with a sitetree as e.g. the
visibleinnav attribute?
IMO visibility in the navigation is a rather general feature
which shouldn't apply to sitetrees only, but to any site structure.
How could this be solved in a generic way?
Maybe:
String getAttribute(Document document, String name);
void setAttribute(Document document, String name, String value);
Map getAttributes(Document document);
But it doesn't really make sense because the attributes are associated
with nodes, not with documents.
Should there be an abstraction of a node (=set of all language versions
of a document) in Lenya?
There is such a class (o.a.lenya.cms.site.Node) which could be
used for this purpose.
What about o.a.l.cms.site.tree.SiteTree.java (see above)?
Or should there be no sitetree attributes at all, only meta data?
IMO yes, there should be only meta data.
Should the "visibleinnav" informations be stored in the metadata? does
that really make sense?
That depends:
If there's a 1:1 mapping from documents to site nodes (which we have now),
I see no problem in using the meta data.
If there's a 1:n mapping, the information shouldn't be stored in the
document, but in the node. But actually I'd implement this with references,
which means that the visibility information can be stored in the placeholder
document's meta data.
-- Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]