Skip to content

Welshman Docs / @welshman/domain / MuteListReader

Class: MuteListReader

Defined in: kinds/MuteList.ts:8

A reader that has to decrypt (or otherwise await something) before its accessors are complete. parse() returns a promise, so the type system makes callers await it rather than silently reading a half-parsed event.

Extends

Constructors

Constructor

new MuteListReader(kind, context, event): MuteListReader

Defined in: core/EventReader.ts:17

Parameters

kind

number

context

KindContext

event

TrustedEvent

Returns

MuteListReader

Inherited from

ListReader.constructor

Properties

context

readonly context: KindContext

Defined in: core/EventReader.ts:19

Inherited from

ListReader.context


decrypted

decrypted: boolean = false

Defined in: core/ListReader.ts:6

Inherited from

ListReader.decrypted


event

readonly event: TrustedEvent

Defined in: core/EventReader.ts:20

Inherited from

ListReader.event


kind

readonly kind: number

Defined in: core/EventReader.ts:18

Inherited from

ListReader.kind


privateTags

privateTags: string[][] = []

Defined in: core/ListReader.ts:8

Inherited from

ListReader.privateTags


publicTags

publicTags: string[][] = []

Defined in: core/ListReader.ts:7

Inherited from

ListReader.publicTags

Methods

address()

address(): string

Defined in: core/EventReader.ts:55

Returns

string

Inherited from

ListReader.address


author()

author(): string

Defined in: core/EventReader.ts:35

Returns

string

Inherited from

ListReader.author


content()

content(): string

Defined in: core/EventReader.ts:39

Returns

string

Inherited from

ListReader.content


createdAt()

createdAt(): number

Defined in: core/EventReader.ts:47

Returns

number

Inherited from

ListReader.createdAt


emojis()

emojis(): Emoji[]

Defined in: core/EventReader.ts:71

Returns

Emoji[]

Inherited from

ListReader.emojis


expiration()

expiration(): undefined | number

Defined in: core/EventReader.ts:67

Returns

undefined | number

Inherited from

ListReader.expiration


id()

id(): string

Defined in: core/EventReader.ts:31

Returns

string

Inherited from

ListReader.id


identifier()

identifier(): undefined | string

Defined in: core/EventReader.ts:51

Returns

undefined | string

Inherited from

ListReader.identifier


includes()

includes(pubkey): boolean

Defined in: kinds/MuteList.ts:13

Parameters

pubkey

string

Returns

boolean


parse()

parse(): Promise<MuteListReader>

Defined in: core/ListReader.ts:10

Returns

Promise<MuteListReader>

Inherited from

ListReader.parse


protect()

protect(): boolean

Defined in: core/EventReader.ts:63

Returns

boolean

Inherited from

ListReader.protect


pubkeys()

pubkeys(): string[]

Defined in: kinds/MuteList.ts:9

Returns

string[]


room()

room(): undefined | string

Defined in: core/EventReader.ts:59

Returns

undefined | string

Inherited from

ListReader.room


tags()

tags(): string[][]

Defined in: core/ListReader.ts:38

Returns

string[][]

Inherited from

ListReader.tags


zapSplits()

zapSplits(): ZapSplit[]

Defined in: core/EventReader.ts:75

Returns

ZapSplit[]

Inherited from

ListReader.zapSplits