Objects file
In your objects.json file, store data in the following three sections:
- Properties: Define property definitions including name, display name, data type, unit of measure, editable flag and so on. Property defintions will be referenced by type properties and object properties in the other two sections.
- Types: Define object types from your CAD model, such as pipe types or wall types.
- Objects: Define the object instances in your CAD model, which are instances of the defined types, for example, specific pipe or wall instances.
These sections must occur in the exact order as described, to support incremental parsing of the package file.
For a breakdown of each array and their object schemas, see the following links:
The following is objects.json file schema.
objects.json overall data structure#
{ "properties": [ { "id": "integer", "name": "string", "dname": "string", "type": { "enum": [ "STRING", "BOOLEAN", "INTEGER", "LONG", "DOUBLE", "FLOAT", "DATE" ] }, "uom": "string", "edit": "boolean", "psName": "string", "psDispName": "string" } ], "types": [ { "id": "integer", "sourceId": "guid" | "integer" | "string", "name": "string", "properties": [ { "id": "integer", "name": "string", "val": "various data types", //consistent with data type in property definition "dVal": "string", //optional, display text value for UI function use } ] } ], "objects": [ { "id": "integer", "type": "integer", "sourceId": "guid", "properties": [ { "id": "integer", "name": "string", "val": "various data types", //consistent with data type in property definition) "dVal": "string", //optional, display text value for UI function use } ], "relationships": { "aggregates": ["integer"], "aggregated_by": "integer", "contains_in_spatial_structure": ["integer"], "contained_by_spatial_structure": "integer", "references_in_spatial_structure": ["integer"], "referenced_by_spatial_structure": ["integer"] } } ]}