name: Event

description: A representation of a system event. These are generated via the Metadata interfaces and specific to a specific Substrate runtime

Type parameters

S : ConstructorDef

T : object

V : object

E : object

Hierarchy

↳ Struct

↳ Event

Implements

Constructors

constructor

⊕ new Event(value?: *[Uint8Array](_codec_u8a.u8a.md#uint8array)*): Event

Overrides Struct.constructor

Defined in Event.ts:86

Parameters:

Name Type
Optional _value Uint8Array

Returns: Event


Accessors

Type

getType(): E

Inherited from Struct.Type

Defined in codec/Struct.ts:142

description: Returns the Type description to sthe structure

Returns: E


data

getdata(): EventData

Defined in Event.ts:144

description: The wrapped EventData

Returns: EventData


encodedLength

getencodedLength(): number

Inherited from Struct.encodedLength

Defined in codec/Struct.ts:149

description: The length of the value when encoded as a Uint8Array

Returns: number


index

getindex(): EventIndex

Defined in Event.ts:151

description: The EventIndex, identifying the raw event

Returns: EventIndex


meta

getmeta(): EventMetadata

Defined in Event.ts:158

description: The EventMetadata with the documentation

Returns: EventMetadata


method

getmethod(): string

Defined in Event.ts:165

description: The method string identifying the event

Returns: string


section

getsection(): string

Defined in Event.ts:172

description: The section string identifying the event

Returns: string


typeDef

gettypeDef(): Array<TypeDef>

Defined in Event.ts:179

description: The TypeDef for the event

Returns: Array<TypeDef>


Methods

eq

▸ eq(other?: any): boolean

Implementation of Codec.eq

Inherited from Struct.eq

Defined in codec/Struct.ts:158

description: Compares the value of the input to see if there is a match

Parameters:

Name Type
Optional other any

Returns: boolean


get

▸ get(name: keyof S): Codec | undefined

Inherited from Struct.get

Overrides Map.get

Defined in codec/Struct.ts:166

description: Returns a specific names entry in the structure

Parameters:

Name Type Description
name keyof S The name of the entry to retrieve

Returns: Codec | undefined


getAtIndex

▸ getAtIndex(index: number): Codec

Inherited from Struct.getAtIndex

Defined in codec/Struct.ts:173

description: Returns the values of a member at a specific index (Rather use get(name) for performance)

Parameters:

Name Type
index number

Returns: Codec


toArray

▸ toArray(): Array<Codec>

Inherited from Struct.toArray

Defined in codec/Struct.ts:180

description: Converts the Object to an standard JavaScript Array

Returns: Array<Codec>


toHex

▸ toHex(): string

Implementation of Codec.toHex

Inherited from Struct.toHex

Defined in codec/Struct.ts:187

description: Returns a hex string representation of the value

Returns: string


toJSON

▸ toJSON(): any

Implementation of Codec.toJSON

Inherited from Struct.toJSON

Defined in codec/Struct.ts:194

description: Converts the Object to JSON, typically used for RPC transfers

Returns: any


toString

▸ toString(): string

Implementation of Codec.toString

Inherited from Struct.toString

Defined in codec/Struct.ts:208

description: Returns the string representation of the value

Returns: string


toU8a

▸ toU8a(isBare?: undefined | false | true): Uint8Array

Implementation of Codec.toU8a

Inherited from Struct.toU8a

Defined in codec/Struct.ts:216

description: Encodes the value as a Uint8Array as per the parity-codec specifications

Parameters:

Name Type Description
Optional isBare undefined false true true when the value has none of the type-specific prefixes (internal)

Returns: Uint8Array


<Static> decodeEvent

▸ decodeEvent(value?: Uint8Array): object | object

Defined in Event.ts:98

Parameters:

Name Type Default value
Default value value Uint8Array new Uint8Array()

Returns: object | object


<Static> injectMetadata

▸ injectMetadata(metadata: MetadataV0): void

Defined in Event.ts:122

Parameters:

Name Type
metadata MetadataV0

Returns: void


<Static> with

▸ with<S>(Types: S): Constructor<Struct<S>>

Inherited from Struct.with

Defined in codec/Struct.ts:122

Type parameters:

S : ConstructorDef

Parameters:

Name Type
Types S

Returns: Constructor<Struct<S>>


results matching ""

    No results matching ""