[elephant-devel] Re: blog example w/ hunchentoot

Pierre THIERRY nowhere.man at levallois.eu.org
Fri Apr 27 22:36:35 UTC 2007


Scribit Ian Eslick dies 27/04/2007 hora 15:37:
> The persistent slots of that class have the allocation parameter
> :database instead of :instance to capture these semantics.

Should'nt that be orthogonal? Currently, that means persistent class
allocated slots are not supported. I never had to use them, though, so I
didn't think much about their usefulness...

> You might read metaclasses.lisp and classes.lisp if you want a deeper
> understanding of how this works.

Yes, I only gave them a superficial look before, only to add some locks
around slot access (which was surprisingly easy, and though it might not
have been very clean, it was working for me...).

> You can't call reinitialize instance unless you have an instance to
> reinitialize.  When you are deserializing a persistent object
> reference and the object isn't in memory, you need to create storage
> for at least the oid and store-controller reference.

That's making a placeholder instance, not making a persistent class
instance, semantically.

> If you are  creating an object, why not create one using the class of
> the one you are  going to use rather than invoking more generic
> function overhead to copy values around?

Because you're not creating an instance of it, you're creating storage
to hold an already created instance of it.

> I'm open to a better solution to handling slot  initialization in the
> fresh vs. reconstituted cases.

I'll think on it. It's very pleasant to know a proposal will be welcome.

Curiously,
Pierre
-- 
nowhere.man at levallois.eu.org
OpenPGP 0xD9D50D8A
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <https://mailman.common-lisp.net/pipermail/elephant-devel/attachments/20070428/b21787cf/attachment.sig>


More information about the elephant-devel mailing list