Skip to main content

ModuleMetadata

Namespace: IotaSdk

A typed view of an on-chain 0x2::module_metadata::ModuleMetadata object, the per-module key-value store owned by a package's PackageMetadataV1.

public class ModuleMetadata : IModuleMetadata, System.IDisposable

Inheritance ObjectModuleMetadata
Implements IModuleMetadata, IDisposable
Attributes NullableContextAttribute, NullableAttribute

Constructors

ModuleMetadata(UInt64)

public ModuleMetadata(ulong pointer)

Parameters

pointer UInt64

Methods

Destroy()

public void Destroy()

Dispose()

public void Dispose()

Id()

The object's ID.

public ObjectId Id()

Returns

ObjectId

Size()

The number of key-value pairs stored in the metadata's dynamic fields. The entries themselves (e.g. the view-function names) live in dynamic fields, not in this object's contents.

public ulong Size()

Returns

UInt64

TryFromBcs(Byte[])

Decode from BCS bytes, without validating the on-chain type tag.

public static ModuleMetadata TryFromBcs(Byte[] bytes)

Parameters

bytes Byte[]

Returns

ModuleMetadata

Exceptions

SdkFfiException

TryFromObject(Object)

Decode from an on-chain object, validating its Move type tag.

public static ModuleMetadata TryFromObject(Object object)

Parameters

object Object

Returns

ModuleMetadata

Exceptions

SdkFfiException