View · Search · Index
No registered users in community xowiki
in last 10 minutes

Re: [Xotcl] Initialisation arguments

From: Gustaf Neumann <neumann_at_wu-wien.ac.at>
Date: Fri, 20 Oct 2006 22:11:42 +0200

Kristoffer Lawson schrieb:
> Are these stored anywhere within XOTcl? If not, I presume that
> information is not currently available to the script end? I'm just
> wondering as I think I could make good use of that with object
> recreation based on its serialised form.
Kristoffer,

i am not sure, i understood your question. however, there is no hidden
information
in xotcl, which is not accessible for a script writer.

The default values for attributes are stored as ordinary attributes in
the slot objects. the
Attribute slot objects have for this purpose the attribute named
"default". See:
http://media.wu-wien.ac.at/doc/tutorial.html#attribute-slots

If objects are serialized with the xotcl serializer, they are serialized
with their current settings.
In other words, the object created after derserialization is identical
to the object which was
serialize.

Per default, the slot objects are created as child objects of the class.
That means, if
someone serializes the class as well, the default values are kept as
well in the serialized
state.

-gustaf