Class: StoredEvent

StoredEvent(roomId, eventId, remoteRoomId, remoteEventId, extras)

new StoredEvent(roomId, eventId, remoteRoomId, remoteEventId, extras)

Create a store event.
Parameters:
Name Type Description
roomId string The matrix room ID
eventId string The matrix event ID
remoteRoomId string The remote room ID
remoteEventId string The remote event ID
extras any Any extra data that may be included with the event.
Source:

Methods

(static) deserialize(data)

Set data about this event from a serialized data object.
Parameters:
Name Type Description
data Object The serialized data
Source:

get(key) → {*}

Get the data value for the given key.
Parameters:
Name Type Description
key string An arbitrary bridge-specific key.
Source:
Returns:
Stored data for this key. May be undefined.
Type
*

getId() → {string}

Get the unique ID.
Source:
Returns:
A unique ID
Type
string

getMatrixEventId() → {string}

Get the matrix event ID.
Source:
Returns:
The event ID
Type
string

getMatrixRoomId() → {string}

Get the matrix room ID.
Source:
Returns:
The room ID
Type
string

getRemoteEventId() → {string}

Get the remote event ID.
Source:
Returns:
The remote event ID
Type
string

getRemoteRoomId() → {string}

Get the remote room ID.
Source:
Returns:
The remote room ID
Type
string

serialize() → {Object}

Serialize data about this event into a JSON object.
Source:
Returns:
The serialised data
Type
Object

set(key, val)

Set an arbitrary bridge-specific data value for this event. This will be serailized under an 'extras' key.
Parameters:
Name Type Description
key string The key to store the data value under.
val * The data value. This value should be serializable via JSON.stringify(data).
Source: