Autodesk.Gis.Map.ObjectData Namespace

Land Desktop Map 3D Samples

 
Autodesk.Gis.Map.ObjectData Namespace
 
 
 

Some of the following information is extracted from the sdk.ref.net.chm by clicking the Index tab and double-clicking the “ObjectData Record”entry. The rest is a description of what happens in the sample code.

Object data provides a way of attaching additional information to drawing objects.

Each drawing has its own set of tables, available from the ProjectModel.ODTables property. This returns an object of type ObjectData.Tables. This object contains objects of type ObjectData.Table.

Columns in anObjectData.Tableobject are defined by ObjectData.FieldDefinition objects. A FieldDefinition object contains a Utilities.MapValue object. The latter contains a key-value pair. The key is the column name and the value is a Constants.DataType value. The ObjectData.FieldDefinition objects are added to an ObjectData.FieldDefinitions object and then the latter is added to the ProjectModel.ODTables property along with a table name. The result is that an object of type ObjectData.Table can be retrieved from the ProjectModel.ODTables property using the table name as an index.

Each row in a ObjectData.Table table is of type ObjectData.Record. This type can be viewed as an array of Autodesk.Gis.Map.Utilities.MapValue objects. Each Utilities.MapValue object is a key-value pair. The key is a column name that is one of the column names found in the FieldDefinition objects used to define the ObjectData.Table table.

Every record in the table is associated with a drawing object. This is done using an Autodesk.AutoCAD.DatabaseServices.ObjectId object, which identifies a DatabaseServices.Entity object inside a DatabaseServices.BlockTableRecord object inside a DatabaseServices.BlockTable object inside a DatabaseServices.Database object inside a DatabaseServices.ProjectModel object, which is the active project. The DatabaseServices.Entity object may appear in a DWG drawing.