Repository CreateObjectEx Method

Meta Data Services Programming

Meta Data Services Programming

Repository CreateObjectEx Method

This method creates the first version of a new repository object instance of the specified type and explicitly assigns the object-version identifier that is passed in as an argument. This is unlike the CreateObject method, in which the repository engine assigns the version ID.

This property is not attached to the default interface for the repository Automation object; it is attached to the IRepository2 interface. For more information about accessing a member of an interface that is not the default interface, see Accessing Automation Object Members.

Syntax

set variable  =  object.CreateObjectEx(typeID, objID, extVersionID)

The CreateObjectEx method syntax has the following parts.

Part Description
variable Declared as a RepositoryObjectVersion. It receives the new RepositoryObjectVersion.
object The object that represents the open repository instance through which application code or a tool interacts with a repository.
typeId The object identifier of the class to which the new object conforms. For example, to create an instance of a Storage class, specify the object identifier of the Storage class.
objectId The object identifier to be assigned to the new object. Either pass in ObjID_NULL, or leave unspecified to have an object identifier assigned automatically.
extVersionID The external object-version identifier.
Remarks

This method provides an alternate approach for creating an object instance. To allow the repository engine to create an object identifier for you, use the CreateObject method.

See Also

Repository CreateObject Method

Repository Object

Assigning Object Identifiers