Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 6 Metadata : Creating Classes Based on Metadata Objects

Creating Classes Based on Metadata Objects
The SDK parses metadata objects found in the project repository and populates the class registry. By default, this happens upon startup.
Metadata Description Classes
Metadata description classes encapsulate the metadata description. For example:
MModeledClassDescription encapsulates the descriptions of the classes themselves. It describes MInstance.
MSequenceClassDescription encapsulates attribute types that are sequences. It describes MSequence.
MOperationParameterDescription encapsulates operation parameters. It describes the expected inputs and outputs for an ActiveEnterprise operation.
In the C++ SDK, MPrimitiveClassDescription encapsulates simple attribute type descriptions. It governs such classes as MInteger, MBinary, or MReal. (The Java SDK uses Java native classes in this case).
When the SDK reads the metadata from the adapter instance in the repository, each attribute must have a name and type. The SDK creates an MAttributeDescription for each attribute. Custom adapters can then set the attributes when they send the information over the wire. Custom adapters can also access the following information.
Metadata Hierarchy Example
Assume you have created an Order class with four attributes. Three of the attributes are strings, the other, Orderlines, is a sequence of four attributes.
In this case, MApp would generate one MModeledClassDescription with four associated MAttributeDescription instances for the Order class, as well as one MModeledClassDescription with four associated MAttributeDescription instances for the OrderLine class. MApp also creates an MSequenceClassDescription consisting of one or more OrderLine instances.
Order class
MModeledClassDescription with four associated MAttributeDescription classes.
OrderLine class
MModeledClassDescription with four associated MAttributeDescription classes.

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved