[Tutor] Modifying Source Code while Program is Running

Alan Gauld alan.gauld at freenet.co.uk
Sun Nov 27 00:03:34 CET 2005

>From this and what Alan said, I think I'm starting to get it.  Each
> attribute could be an object or an entry in a list.  Each type would
> be a collection or list of a particular set of attributes.  The
> collection of types would be an object which is easily persisted.


> Can you create an object whose default action is to return a certain
> value?  For example could I have a header object that where when you
> call page.header it returns a value but I can also have
> page.header.update().  

Absolutely, in fact its quite normal.

> Or (I think) I know that methods can have
> attributes, but can attributes have methods?

They can if the attributes are objects in their own right...


Alan G.

More information about the Tutor mailing list