CreateMDSClassDesc2
Purpose
Creates a new class description and contains it in the current model.
Description
The class can be used to create its associated property descriptions. It can also be used in new relationship description definitions.
The default OwnerID is the logged in user. The class's versioning support will be set from the AIM's versioning support.
Requirements
Class names must be unique within an AIM.
Syntax
HRESULT CreateMDSClassDesc2(
CMetaClassDesc *&pClassObj,
LPCTSTR strClassName,
LPCTSTR strClassDesc,
const short sUniqueNamesFlag,
const GUID& gClassID,
const OBJECTID_t lOwnerID,
const OBJECTID_t SecurityProfileID,
const bool bRootClass,
const bool bAbstractClass,
const bool bDescriptionRequired,
MetaObjectIDVector &superClasses);
Argument |
In/Our |
Description |
pClassObj |
in/out |
Pointer to Class Desc object. If pClassObj is a pointer to NULL, the object will be created by the API. The calling application is responsible for freeing the object. |
strClassName |
in |
name of the class |
strClassDesc |
in |
description of class |
sUniqueNamesFlag |
in |
MD_UNIQUE = maintain unique names, MD_NULL = do not maintain unique names, default is MD_NULL |
gClassID |
in |
Global unique identifier to assign to this class |
lOwnerID |
in |
OwnerID of this object |
SecurityProfileID |
in |
Security Profile assigned to the object. |
bRootClass |
in |
True = set this class to be a root class of the model. The MDS browsers begin tree displays of the data in the model at the root classes. |
bAbstractClass |
in |
If true, creates the class as an abstract class. An abstract class does not have instances. It is created to enable inheritance of properties and relationships. |
bDescriptionRequired |
in |
Indicates if an object in the class must have a non-null Description property. Classes in protected metamodels (DIM, CLM, and CWM) may not set this value to True. |
superClasses |
in |
The list of superclasses that the new class will inherit properties and relationships from. The superClasses list can contain zero or one class ids. |