API Reference > OdDb Classes > OdDbDatabase Class > OdDbDatabase Methods > OdDbDatabase::addOdDbObject Method
OdDbDatabase::addOdDbObject Method
Syntax
C++
OdDbObjectId addOdDbObject(OdDbObject* pObject, OdDbObjectId ownerId = OdDbObjectId::kNull, OdDbHandle handle = 0);
Parameters 
Description 
OdDbObject* pObject 
[in] Pointer to the object.  
OdDbObjectId ownerId = OdDbObjectId::kNull 
[in] Object ID of the owner of pObject.  
OdDbHandle handle = 0 
[in] Handle for pObject. 

Adds an object to this database object, and returns its Object ID. 

 

A unique handle will be generated if a handle is not supplied or is 0.

Copyright © 2002–2020. Open Design Alliance. All rights reserved.