Object Type ID
The numeric object type ID uniquely identifies every object type in enaio® (folders, registers, documents, portfolios, notes). In the API it appears, among others, as the parameter objecttypeid (e.g., mng.ExportSecuritySystem), as the XML attribute id on <ObjectType> (DMSContent, DMSData documents), as the return value ObjectType from dms.GetObjectTypeByID, and as the attribute object_type in security system XML structures.
1. Computation
The object type ID is composed of two 16-bit parts:
objecttypeid = (maintype << 16) | cotype
-
maintype— Highword (upper 16 bits): classifies the broad kind of object type. -
cotype— Lowword (lower 16 bits): running subtype index within the class, starting at0.
Both parts can be recovered from a given object type ID:
maintype = (objecttypeid >> 16) & 0xFFFF
cotype = objecttypeid & 0xFFFF
2. Main Types (maintype)
| Object Type | maintype (dec) |
maintype (hex) |
cotype Range |
|---|---|---|---|
Folder |
|
|
|
Document — Grayscale |
|
|
|
Document — Black/White |
|
|
|
Document — Color |
|
|
|
Document — Windows |
|
|
|
Document — Multimedia |
|
|
|
Document — E-Mail |
|
|
|
Document — XML |
|
|
|
Document — Container |
|
|
|
Register |
|
|
|
Typeless document in user tray |
|
|
|
Typeless document in workflow tray |
|
|
|
Portfolio |
|
|
|
Note |
|
|
|
3. Examples
objecttypeid |
maintype |
cotype |
Meaning |
|---|---|---|---|
|
|
|
First cabinet folder |
|
|
|
Second cabinet folder |
|
|
|
First Windows document |
|
|
|
Second Windows document |
|
|
|
First register |
|
|
|
Fourth register / subregister |
4. Runtime Resolution
At runtime an object type ID can be resolved against the object definition:
-
dms.GetObjectTypeByID returns the
ObjectTypedirectly for an object ID. -
dms.GetObjDef returns the full object definition with cabinets, object types and fields. From it the internal name, display name and underlying database table can be derived for a given object type ID.
The XSD schemas in DMSObjDef and DMSContent describe the maintype/cotype attributes at the XML level.