[Gbbopen-list] deleted-unit-instance

Dan Corkill corkill at gbbopen.org
Tue Feb 17 17:36:22 EST 2009


Paul Werkowski wrote:
> The recent side effect of delete-instance changing the class of
> the instance to deleted-unit-instance and thereby losing all
> state information was not anticipated here.

Paul,

We tried to strike a balance between detecting the erroneous use of a
deleted unit instance and retaining some debugging information by keeping
the original class of the deleted unit-instance and its instance-name as
slots in the DELETED-UNIT-INSTANCE object.

However, to give you more control over what is retained in a deleted
unit-instance object, we've added a new generic function,
DELETED-INSTANCE-CLASS used by DELETE-INSTANCE that when called with the
unit instance to be deleted, returns the class name (or class object) to be
used in the CHANGE-CLASS that DELETE-INSTANCE performs.  The default method
(on STANDARD-UNIT-INSTANCE) returns the DELETED-UNIT-INSTANCE class.  You
can define your own subclasses of DELETED-UNIT-INSTANCE (retaining whatever
slots you wish) and add method(s) to DELETED-UNIT-INSTANCE to indicate your
preferred subclass of DELETED-UNIT-INSTANCE.

The new DELETED-INSTANCE-CLASS functionality has been committed to the SVN
repository.  Documentation for it will follow...

-- Dan

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



More information about the Gbbopen-list mailing list