2019-02-11 01:55:29 +05:30
|
|
|
export default class RoomStateStore {
|
|
|
|
constructor(idbStore) {
|
|
|
|
this._roomStateStore = idbStore;
|
|
|
|
}
|
|
|
|
|
|
|
|
async getEvents(type) {
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
async getEventsForKey(type, stateKey) {
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
async setStateEvent(roomId, event) {
|
2019-06-27 01:25:33 +05:30
|
|
|
const key = `${roomId}|${event.type}|${event.state_key}`;
|
|
|
|
const entry = {roomId, event, key};
|
|
|
|
return this._roomStateStore.put(entry);
|
2019-02-11 01:55:29 +05:30
|
|
|
}
|
2019-06-27 01:25:33 +05:30
|
|
|
}
|