[gme-users] implementing remove an atom from a model using BON1

Akos Ledeczi akos.ledeczi at vanderbilt.edu
Wed Jan 25 14:48:20 CST 2006

...and in general it is not a good idea to go to the distributed BON 
files and change them. If you cannot do it with inheritance, you 
probably should not do it at all...


Zoltan Molnar wrote:
> Hi,
> The protected RemoveAtom & co. methods release objects only from the
> Builder structure, [they are used mostly in destructors], and they do
> not provide the functionality you would like to have: to remove an atom
> from the gme model.
> Br,Zoli
>>-----Original Message-----
>>From: gme-users-bounces at list.isis.vanderbilt.edu 
>>[mailto:gme-users-bounces at list.isis.vanderbilt.edu] On Behalf 
>>Of Jane Lin
>>Sent: Wednesday, January 25, 2006 10:54 AM
>>To: gme-users
>>Subject: [gme-users] implementing remove an atom from a model 
>>using BON1
>>I am adding a new function to remove an atom from a model for my GME 
>>interpreter written with BON1. To implement this, I changed 
>>the RemoveAtom 
>>method of the CBuilderModel class from "protected" access to 
>>"public" access 
>>in Builder.h, then I could call it like:
>>//before this I found the atom correctly and assign it to 
>>foundAtom, then
>>theParentModel->RemoveAtom((CBuilderAtom *)foundAtom);
>>It compiled and run successfully, but the atom was still in 
>>the model open 
>>within GME5.9.21.
>>Anyone has comments on this?
>>Yuehua (Jane) Lin
>>Department of Computer and Information Sciences
>>University of Alabama at Birmingham
>>liny at cis.uab.edu
>>gme-users mailing list
>>gme-users at list.isis.vanderbilt.edu
> _______________________________________________
> gme-users mailing list
> gme-users at list.isis.vanderbilt.edu
> http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users

More information about the gme-users mailing list