ExternalPropertyType
public enum ExternalPropertyType : UInt16
External property types for integration with external systems (e.g., other databases). Numeric values start at 100 to avoid overlaps with ObjectBox’s PropertyType.
-
Not a real type: represents uninitialized state and can be used for forward compatibility.
Declaration
Swift
case unknown = 0 -
Representing type: ByteVector Encoding: 1:1 binary representation, little endian (16 bytes)
Declaration
Swift
case int128 = 100 -
Undocumented
Declaration
Swift
case reserved1 = 101 -
UUID (Universally Unique Identifier) as defined by RFC 9562. ObjectBox uses the UUIDv7 scheme (timestamp + random) to create new UUIDs. UUIDv7 is a good choice for database keys as it’s mostly sequential and encodes a timestamp. However, if keys are used externally, consider UuidV4 for better privacy by not exposing any time information. Representing type: ByteVector Encoding: 1:1 binary representation (16 bytes)
Declaration
Swift
case uuid = 102 -
IEEE 754 decimal128 type, e.g., supported by MongoDB. Representing type: ByteVector Encoding: 1:1 binary representation (16 bytes)
Declaration
Swift
case decimal128 = 103 -
UUID represented as a string of 36 characters, e.g., “019571b4-80e3-7516-a5c1-5f1053d23fff”. For efficient storage, consider the Uuid type instead, which occupies only 16 bytes (20 bytes less). This type may still be a convenient alternative as the string type is widely supported and more human-readable. In accordance with standards, new UUIDs generated by ObjectBox use lowercase hexadecimal digits. Representing type: String
Declaration
Swift
case uuidString = 104 -
UUID (Universally Unique Identifier) as defined by RFC 9562. ObjectBox uses the UUIDv4 scheme (completely random) to create new UUIDs. Representing type: ByteVector Encoding: 1:1 binary representation (16 bytes)
Declaration
Swift
case uuidV4 = 105 -
Like UuidString, but using the UUIDv4 scheme (completely random) to create new UUID. Representing type: String
Declaration
Swift
case uuidV4String = 106 -
Key/value map; e.g., corresponds to a JSON object or a MongoDB document (although not keeping the key order). Unlike the Flex type, this must contain a map value (e.g., not a vector or a scalar). Representing type: Flex Encoding: Flex
Declaration
Swift
case flexMap = 107 -
A vector (aka list or array) of flexible elements; e.g., corresponds to a JSON array or a MongoDB array. Unlike the Flex type, this must contain a vector value (e.g., not a map or a scalar). Representing type: Flex Encoding: Flex
Declaration
Swift
case flexVector = 108 -
Placeholder (not yet used) for a JSON document. Representing type: String
Declaration
Swift
case json = 109 -
Placeholder (not yet used) for a BSON document. Representing type: ByteVector
Declaration
Swift
case bson = 110 -
JavaScript source code. Representing type: String
Declaration
Swift
case javaScript = 111 -
A JSON string that is converted to a native representation in the external system. For example, a JSON object on the ObjectBox side (string) would be converted to an embedded document in MongoDB. It depends on the external system what kind of JSON structures are supported. For MongoDB, this is very flexible and allows (nested) objects, arrays, primitives, etc. Representing type: String
Declaration
Swift
case jsonToNative = 112 -
Undocumented
Declaration
Swift
case reserved6 = 113 -
Undocumented
Declaration
Swift
case reserved7 = 114 -
Undocumented
Declaration
Swift
case reserved8 = 115 -
A vector (array) of Int128 values.
Declaration
Swift
case int128Vector = 116 -
Undocumented
Declaration
Swift
case reserved9 = 117 -
A vector (array) of Uuid values.
Declaration
Swift
case uuidVector = 118 -
Undocumented
Declaration
Swift
case reserved10 = 119 -
Undocumented
Declaration
Swift
case reserved11 = 120 -
Undocumented
Declaration
Swift
case reserved12 = 121 -
Undocumented
Declaration
Swift
case reserved13 = 122 -
The 12-byte ObjectId type in MongoDB. Representing type: ByteVector Encoding: 1:1 binary representation (12 bytes)
Declaration
Swift
case mongoId = 123 -
A vector (array) of MongoId values.
Declaration
Swift
case mongoIdVector = 124 -
Representing type: Long Encoding: Two unsigned 32-bit integers merged into a 64-bit integer.
Declaration
Swift
case mongoTimestamp = 125 -
Representing type: ByteVector Encoding: 3 zero bytes (reserved, functions as padding), fourth byte is the sub-type, followed by the binary data.
Declaration
Swift
case mongoBinary = 126 -
Representing type: string vector with 2 elements (index 0: pattern, index 1: options). Encoding: 1:1 string representation.
Declaration
Swift
case mongoRegex = 127 -
Undocumented
Declaration
Swift
public static var max: ExternalPropertyType { get } -
Undocumented
Declaration
Swift
public static var min: ExternalPropertyType { get }
View on GitHub
Install in Dash
ExternalPropertyType Enumeration Reference