Skip to main content
Module

x/polkadot/mod.ts>types.Enum

Package publishing for deno.land/x/polkadot
Go to Latest
class types.Enum
implements IEnum
Re-export
import { types } from "https://deno.land/x/polkadot@0.2.33/mod.ts";
const { Enum } = types;

Constructors

new
Enum(
registry: Registry,
Types: Record<string, string | CodecClass> | Record<string, number> | string[],
value?: unknown,
index?: number,
unnamed 4?: Options,
)

Properties

optional
createdAtHash: IU8a
readonly
defIndexes: number[]
readonly
defKeys: string[]
readonly
encodedLength: number
readonly
hash: IU8a
readonly
index: number
optional
initialU8aLength: number
readonly
inner: Codec
readonly
isBasic: boolean
readonly
isEmpty: boolean
readonly
isNone: boolean
optional
isStorageFallback: boolean
readonly
registry: Registry
readonly
type: string
readonly
value: Codec

Methods

protected
_toRawStruct(): string[] | Record<string, string | number>
eq(other?: unknown): boolean
inspect(): Inspect
toHex(): HexString
toHuman(isExtended?: boolean): AnyJson
toJSON(): AnyJson
toNumber(): number
toPrimitive(): AnyJson
toRawType(): string
toString(): string
toU8a(isBare?: boolean): Uint8Array

Static Methods

with(Types: Record<string, string | CodecClass> | Record<string, number> | string[]): EnumCodecClass<Enum>