OwnerInterface
interface OwnerInterface
Enum of different types of ownership for an object.
BCS
The BCS serialized form for this type is defined by the following ABNF:
owner = owner-address / owner-object / owner-shared / owner-immutable
owner-address = %d00 address
owner-object = %d01 object-id
owner-shared = %d02 u64
owner-immutable = %d03
Inheritors
| Owner |
Functions
| Name | Summary |
|---|---|
| addressOrObject | abstract fun addressOrObject(): Address? Returns an Address if this object is owned by an address or object, and None if it is shared or immutable. |
| asAddress | abstract fun asAddress(): Address Convert this owner into an address owner if it is one, or panic otherwise |
| asObject | abstract fun asObject(): ObjectId Convert this owner into an object owner if it is one, or panic otherwise |
| asOptAddress | abstract fun asOptAddress(): Address? Convert this owner into an address owner if it is one, or return None otherwise |
| asOptObject | abstract fun asOptObject(): ObjectId? Convert this owner into an object owner if it is one, or return None otherwise |
| asOptShared | abstract fun asOptShared(): Version? Convert this owner into a shared owner if it is one, or return None otherwise |
| asShared | abstract fun asShared(): Version Convert this owner into a shared owner if it is one, or panic otherwise |
| isAddress | abstract fun isAddress(): Boolean Check if this is an address owner |
| isImmutable | abstract fun isImmutable(): Boolean Check if this is an immutable owner |
| isObject | abstract fun isObject(): Boolean Check if this is an object owner |
| isShared | abstract fun isShared(): Boolean Check if this is a shared owner |