ObjVer
Object ID and version.
| Name | Description | Type |
|---|---|---|
obj_id | Object ID. | ObjID |
version | Version ID. | ObjVerVersion |
Helper Methods and Properties
⚠️ Note
These helper methods and properties are available when using the npm package @m-filescorporation/uix-vault-messages. Install it in your project to use these helpers. For more information, see Overview/VaultMessages/.
Factory Methods
| Method | Description | Parameters | Returns |
|---|---|---|---|
Create | Create a new ObjVer object with the specified type, internal ID, and version. | type: number internalId: number version: number | ObjVer |
Properties
| Property | Type | Description |
|---|---|---|
ID | number | null | Internal object ID. |
Version | number | null | Internal object Version. |
Type | number | null | Object Type. |
ObjID | ObjID | null | ObjID object. |
IsExternal | boolean | Is the object external? |
Creating Objects
// Create a new ObjVer object with the specified type, internal ID, and version.
const result = ObjVer.Create(0, 0, 0);
Working with Objects
// Extension helpers for ObjVer instances
// Internal object ID.
const id = objverInstance.ID;
objverInstance.ID = 0;
// Internal object Version.
const version = objverInstance.Version;
objverInstance.Version = 0;
// Object Type.
const type = objverInstance.Type;
objverInstance.Type = 0;
// ObjID object.
const objid = objverInstance.ObjID;
objverInstance.ObjID = {};
// Is the object external?
const isexternal = objverInstance.IsExternal;
Example
{
"obj_id": {
"type": 0,
"item_id": {
"internal_id": 0,
"external_repository_id": {
"connection": "<connection>",
"item": "<item>"
}
}
},
"version": {
"type": 7 /* Enum: ObjVerVersionType */,
"internal_version": 0,
"external_repository_version": "<external repository version>",
"external_repository_sort_key": 0
}
}