ic-reactor
    Preparing search index...

    Class VecClass<T>

    Represents an IDL Array

    Arrays of fixed-sized nat/int type (e.g. nat8), are encoded from and decoded to TypedArrays (e.g. Uint8Array). Arrays of float or other non-primitive types are encoded/decoded as untyped array in Javascript.

    Type Parameters

    • T

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    _type: types.IDL.Type<T>

    Accessors

    • get typeName(): IdlTypeName

      Returns IdlTypeName

    • get name(): string

      Returns string

    Methods

    • Parameters

      • typeTable: TypeTable

      Returns void

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

      Parameters

      • typeTable: TypeTable

      Returns Uint8Array<ArrayBufferLike>

    • Type Parameters

      • T

      Parameters

      • instance: any

      Returns instance is types.IDL.VecClass<T>

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

      Parameters

      • x: any

      Returns x is T[]

    • Internal

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

      Parameters

      • x: T[]

      Returns Uint8Array

    • Parameters

      • typeTable: TypeTable

      Returns void

    • Returns string

    • Parameters

      • x: T[]

      Returns string