[gme-users] creating instance of a model

Akos Ledeczi akos.ledeczi at vanderbilt.edu
Tue Jun 15 12:58:42 CDT 2004


That version does not support this. Why don't you upgrade?

Akos

Perdikis Dimitris wrote:
> Hi,
> First of all I'm using GME 3, release r3.10.13
> But CBuilderModel class has the function
> CBuilderModel *CreateNewModel(CString kindName)  that takes only one
> parameter.
> So when i call this function, i create models that become types (archetypes)
> 
> Let's assume that i create a model "Fiat" (its kind is"Car"). How can i
> create then an instance of model "Fiat"?
> 
> Thanks,
> Dimitris.
> 
> 
> 
> ----- Original Message ----- 
> From: "Akos Ledeczi" <akos.ledeczi at vanderbilt.edu>
> To: "A list for GME users to share thoughts and discuss bugs and fixes."
> <gme-users at list.isis.vanderbilt.edu>
> Sent: Monday, June 14, 2004 5:47 PM
> Subject: Re: [gme-users] creating instance of a model
> 
> 
> 
>>Both CBuilderFolder and CBuilderModel have the following functions:
>>
>>CBuilderModel *CreateNewModel(CString kindName,
>>CBuilderModel* baseType = NULL,
>>bool instance = true);
>>CBuilderAtom  *CreateNewAtom(CString kindName,
>>CBuilderAtom* baseType = NULL,
>>bool instance = true);
>>CBuilderModelReference *CreateNewModelReference(CString kindName,
>>CBuilderObject* refTo);
>>CBuilderReference *CreateNewReference(CString kindName,
>>CBuilderObject* refTo,
>>CBuilderReference* baseType = NULL,
>>bool instance = true);
>>CBuilderSet *CreateNewSet(CString kindName,
>>CBuilderSet* baseType = NULL,
>>bool instance = true);
>>
>>If the baseType is not NULL than they'll create derived objects. If
>>instance is true then intances, oetherwise subtypes.
>>
>>But there may be a misunderstanding here. If your paradigm has a kind
>>"Car", you can create models in your project that have "Car" as their
>>kind. They will become types (archetypes). Then you can create subtypes
>>or instances of these objects. You cannot create an instance of a Car
>>from scratch. This may just be a terminology issue though...
>>
>>Akos
>>
>>
>>Perdikis Dimitris wrote:
>>
>>
>>>Hi,
>>>I'm currently working on an interpreter. I want this interpreter to
>>>create instances of each model in the project. Let's assume that my
>>>modeling paradigm has a model kind called "Car". I want for each "Car"
>>>model in my modeling project to create an instance of "Car". But so far
>>>I haven't found any function of the "CBuilderModel" class to perform
>>>this operation. Does anyone have any idea on how this can be done?
>>>
>>>Thanks in advance,
>>>
>>>
>>>------------------------------------------------------------------------
>>>
>>>_______________________________________________
>>>gme-users mailing list
>>>gme-users at list.isis.vanderbilt.edu
>>>http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users
>>
>>_______________________________________________
>>gme-users mailing list
>>gme-users at list.isis.vanderbilt.edu
>>http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users
>>
> 
> 
> 
> _______________________________________________
> 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