Skip to content

NatClass

Defined in: packages/core/src/candid/idl.ts:671

Represents an IDL Nat

new NatClass(): NatClass

NatClass

PrimitiveType.constructor

get name(): string

Defined in: packages/core/src/candid/idl.ts:706

string

PrimitiveType.name


get typeName(): IdlTypeName

Defined in: packages/core/src/candid/idl.ts:672

IdlTypeName

PrimitiveType.typeName

_buildTypeTableImpl(_typeTable): void

Defined in: packages/core/src/candid/idl.ts:300

TypeTable

void

PrimitiveType._buildTypeTableImpl


accept<D, R>(v, d): R

Defined in: packages/core/src/candid/idl.ts:680

D

R

Visitor<D, R>

D

R

PrimitiveType.accept


buildTypeTable(typeTable): void

Defined in: packages/core/src/candid/idl.ts:260

TypeTable

void

PrimitiveType.buildTypeTable


checkType(t): Type

Defined in: packages/core/src/candid/idl.ts:293

Type

Type

PrimitiveType.checkType


covariant(x): x is bigint

Defined in: packages/core/src/candid/idl.ts:684

Assert that JavaScript’s x is the proper type represented by this Type.

any

x is bigint

PrimitiveType.covariant


decodeValue(b, t): bigint

Defined in: packages/core/src/candid/idl.ts:701

PipeArrayBuffer

Type

bigint

PrimitiveType.decodeValue


display(): string

Defined in: packages/core/src/candid/idl.ts:251

string

PrimitiveType.display


encodeType(): Uint8Array<ArrayBufferLike>

Defined in: packages/core/src/candid/idl.ts:697

Implement I in the IDL spec. Encode this type for the type table.

Uint8Array<ArrayBufferLike>

PrimitiveType.encodeType


encodeValue(x): Uint8Array

Defined in: packages/core/src/candid/idl.ts:693

Internal

Encode the value. This needs to be public because it is used by encodeValue() from different types.

number | bigint

Uint8Array

PrimitiveType.encodeValue


valueToString(x): string

Defined in: packages/core/src/candid/idl.ts:710

bigint

string

PrimitiveType.valueToString


static [hasInstance](instance): instance is NatClass

Defined in: packages/core/src/candid/idl.ts:676

any

instance is NatClass