[Zope] - OO paradigm

Gabe Wachob gwachob@findlaw.com
Thu, 21 Jan 1999 13:51:54 -0800


--------------AB0CD7111BAAE09C2740A090
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Paulo Eduardo Neves wrote:

> Michael Bernstein wrote:
> >
> > An example would be an event calendar, where events can be organized
> > chronologicaly ( Years>Months>Days) but also according to an event
> > category heirarchy (All events>entertainment>music>concerts). These
> > heirarchies only intersect at the leaf node of an individual event.
> >
> > Most product catalogs can be profitably organized using multiple
> > heirarchies as well.
> >
> > So how would you do this in Zope? you could of course represent the
> > alternative heirarchies by branching off the bottom of the primary, or
> > as folder properties, but that doesn't seem as elegant or maintainable.
> > perhaps the answer is some sort of 'pseudo heirarchy' object that could
> > be placed at or near the top of the object tree.
> >
> > What do you all think?
>
> It would be nice if Zope object hierarchy wouldn't be a hierarchy :-)
> Instead of a object tree we would have a object lattice. This is viable
> since we always have the info about which path to follow in the lattice,
> it is the object URL.
>
> It would be great for multilingual web sites. We would have paths to the
> same object like:
> http://www.mysite.com/section/object            #default language
> http://www.mysite.com/french/section/object     #french view of the site
> http://www.mysite.com/german/section/object     #german view
>

Wouldn't a simple change (don't even know if its needed) involving the way
the ORB works be enough?

A simple way to do this: you write a folderish object that is able to
"intercept" ORB requests to its children and can process the URL invocation
itself? Perhaps by rewriting and redispatching the request? Wouldn't that be
enough?

e.g.:

http://www.mysite.com/redirector/chinese/welcome
http://www.mysite.com/redirector/english/welcome
http://www.mysite.com/redirector/esperanto/welcome

    -Gabe


--------------AB0CD7111BAAE09C2740A090
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Paulo Eduardo Neves wrote:
<blockquote TYPE=CITE>Michael Bernstein wrote:
<br>>
<br>> An example would be an event calendar, where events can be organized
<br>> chronologicaly ( Years>Months>Days) but also according to an event
<br>> category heirarchy (All events>entertainment>music>concerts). These
<br>> heirarchies only intersect at the leaf node of an individual event.
<br>>
<br>> Most product catalogs can be profitably organized using multiple
<br>> heirarchies as well.
<br>>
<br>> So how would you do this in Zope? you could of course represent the
<br>> alternative heirarchies by branching off the bottom of the primary,
or
<br>> as folder properties, but that doesn't seem as elegant or maintainable.
<br>> perhaps the answer is some sort of 'pseudo heirarchy' object that
could
<br>> be placed at or near the top of the object tree.
<br>>
<br>> What do you all think?
<p>It would be nice if Zope object hierarchy wouldn't be a hierarchy :-)
<br>Instead of a object tree we would have a object lattice. This is viable
<br>since we always have the info about which path to follow in the lattice,
<br>it is the object URL.
<p>It would be great for multilingual web sites. We would have paths to
the
<br>same object like:
<br><a href="http://www.mysite.com/section/object">http://www.mysite.com/section/object</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
#default language
<br><a href="http://www.mysite.com/french/section/object">http://www.mysite.com/french/section/object</a>&nbsp;&nbsp;&nbsp;&nbsp;
#french view of the site
<br><a href="http://www.mysite.com/german/section/object">http://www.mysite.com/german/section/object</a>&nbsp;&nbsp;&nbsp;&nbsp;
#german view
<br><a href="http://www.learn.fplf.org.br/neves/mensagempager.html"></a>&nbsp;</blockquote>
Wouldn't a simple change (don't even know if its needed)&nbsp;involving
the way the ORB&nbsp;works be enough?
<p>A simple way to do this: you write a folderish object that is able to
"intercept"&nbsp;ORB requests to its children and can process the URL invocation
itself?&nbsp;Perhaps by rewriting and redispatching the request?&nbsp;Wouldn't
that be enough?
<p>e.g.:
<p><A HREF="http://www.mysite.com/redirector/chinese/welcome">http://www.mysite.com/redirector/chinese/welcome</A>
<br><A HREF="http://www.mysite.com/redirector/english/welcome">http://www.mysite.com/redirector/english/welcome</A>
<br><A HREF="http://www.mysite.com/redirector/esperanto/welcome">http://www.mysite.com/redirector/esperanto/welcome</A>
<p>&nbsp;&nbsp;&nbsp; -Gabe
<br>&nbsp;</html>

--------------AB0CD7111BAAE09C2740A090--