[Zope-PTK] Getting it all to work ;-)

Jimmie Houchin jhouchin@texoma.net
Fri, 30 Jun 2000 16:25:29 -0500


I have been reading some stuff by Alan Holub on OOUI. One of the things
he stresses is that OOP isn't just using objects or programming with
classes. It is programming with/to 'interfaces' and 'objects'. An object
is an encapsulation of capabilities. He stresses that ALL actions upon
an object should be done by the object itself. This point stresses
encapsulation. ie: don't mess with the insides of another object.

I think this could also go to a previous question as to (paraphrase)
'why do racks have the object delete itself?'. 

This methodology helps to protect users of an object from breaking when
an object changes. If the user of an object uses the object's interface
and has the object act upon itself, then when the object changes, the
object will still do the right thing.

I am not trying to speak for Phillip or Ty or whomever, but just trying
to provide some possible reasoning for the decisions.

Jimmie Houchin


Ty Sarna wrote:
> 
> In article <395A4873.D054FD73@digicool.com>,
> Shane Hathaway  <shane@digicool.com> wrote:
> > On a related note: Can someone tell me why it is that PTK has been
> > designed to store information about users in the user objects?  Why not
> > store the preferences in the member folders?  Wouldn't that be easier
> > and more logical??
> 
> To my, it seems to me that a user's preferences are logically a property
> of the user.
> 
> As far as practical reasons:
> 
>  - Not every kind of portal will want to give every user a folder. If
>    you have a huge number of users, you may not wish to create a folder
>    for a user until they request one, especially if many/most users will
>    never bother.
> 
>  - not every kind of portal will want to give members folders at all.
>    If you're a company with 782,000 customers and your site is a
>    customer satisfaction survey site or somesuch, you don't allow users
>    to publish on the site anyway and really don't want to have 782,000
>    never-to-be-used objects hanging around.  You probably also want to
>    get information out of your existing customer database
>    anyway, rather than trying to keep ZODB in sync somehow.
> 
> _______________________________________________
> Zope-PTK maillist  -  Zope-PTK@zope.org
> http://lists.zope.org/mailman/listinfo/zope-ptk
> 
> See http://www.zope.org/Products/PTK/Tracker for bug reports and feature requests