Modeling Services > Dynamic Modeling Services > Defining a Dynamic Model > Using the Dynamic Model Interpreter API
 
Using the Dynamic Model Interpreter API
In an Rogue Wave® Server application, the model is defined in a runtime model interpreter, known as the server model interpreter. If your Server application is based on a static model, this server model interpreter is informed by the various macros such as ILS_OBJECT_BEGIN, ILS_ENTRY_STRING, and so forth. The server model interpreter is used transparently by the dynamic view service to inspect the Server model. This interpreter is implemented by the class IlsModelInterpreter, which stores the definition of the Server model:
*Each class is represented by an instance of IlsObjectType.
*Each attribute is represented by an instance of IlsAttributeDef.
*Each relation is represented by an instance of IlsRelationDef.
*Each member function is represented by an instance of IlsFunctionDef.
The server model interpreter stores accessors and modifiers of the various model elements, which are used by the dynamic view services to access and modify the Server model.
When you choose to work with the dynamic modeling services, the description of the model elements is passed on to the server model interpreter directly through the IlsDynModelIntepreter API.
The class IlsDynModelInterpreter provides all the API you need to define a dynamic model. It allows you to define:
*dynamic classes (but no multiple inheritance supported);
*dynamic relations (ownership/use, unary/n-ary, inverse relations);
*dynamic attributes (entry/derived data members, or regular attributes);
*dynamic methods with Rogue Wave Views Script or C++ implementation.
Note: As soon as a dynamic element has been registered, you can no longer remove it.
The dynamic model interpreter extends the standard server model interpreter.

Version 5.8
Copyright © 2014, Rogue Wave Software, Inc. All Rights Reserved.