Skip to content

Welshman Docs / @welshman/domain / RoomListReader

Class: RoomListReader

Defined in: kinds/RoomList.ts:33

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 RoomListReader(kind, context, event): RoomListReader

Defined in: core/EventReader.ts:17

Parameters

kind

number

context

KindContext

event

TrustedEvent

Returns

RoomListReader

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


parse()

parse(): Promise<RoomListReader>

Defined in: core/ListReader.ts:10

Returns

Promise<RoomListReader>

Inherited from

ListReader.parse


protect()

protect(): boolean

Defined in: core/EventReader.ts:63

Returns

boolean

Inherited from

ListReader.protect


relays()

relays(): string[]

Defined in: kinds/RoomList.ts:42

Returns

string[]


room()

room(): undefined | string

Defined in: core/EventReader.ts:59

Returns

undefined | string

Inherited from

ListReader.room


rooms()

rooms(): string[]

Defined in: kinds/RoomList.ts:34

Returns

string[]


roomsForUrl()

roomsForUrl(url): string[]

Defined in: kinds/RoomList.ts:50

Parameters

url

string

Returns

string[]


roomTags()

roomTags(): string[][]

Defined in: kinds/RoomList.ts:38

Returns

string[][]


tags()

tags(): string[][]

Defined in: core/ListReader.ts:38

Returns

string[][]

Inherited from

ListReader.tags


urls()

urls(): string[]

Defined in: kinds/RoomList.ts:46

Returns

string[]


zapSplits()

zapSplits(): ZapSplit[]

Defined in: core/EventReader.ts:75

Returns

ZapSplit[]

Inherited from

ListReader.zapSplits