The Matrix client object to use
Private
Readonly
clientThe Matrix client object to use
Private
Readonly
parsedMaps the original key from the push rules to a list of property names after unescaping.
Static
Private
cachedOptional
actions?: IActionsObjectOptional
rule?: IAnnotatedPushRuleGet the user's push actions for the given event
Private
createPrivate
eventPrivate
eventPrivate
eventPrivate
eventCheck whether the given event matches the push rule condition by fetching the property from the event and comparing against the condition's glob-based pattern.
The push rule condition to check for a match.
The event to check for a match.
Private
eventCheck whether the given event matches the push rule condition by fetching the property from the event and comparing exactly against the condition's value.
The push rule condition to check for a match.
The event to check for a match.
Private
eventCheck whether the given event matches the push rule condition by fetching the property from the event and comparing exactly against the condition's value.
The push rule condition to check for a match.
The event to check for a match.
Private
eventPrivate
eventGet one of the users push rules by its ID
The ID of the rule to search for
rule The push rule, or null if no such rule was found
Private
matchingOptional
rulesets: IPushRulesPrivate
matchingPrivate
pushOptional
rulesets: IPushRulesOptional
actions?: IActionsObjectOptional
rule?: IAnnotatedPushRulePrivate
templatePre-caches the parsed keys for push rules and cleans out any obsolete cache entries. Should be called after push rules are updated.
The new push rules.
Private
valueFor a dotted field and event, fetch the value at that position, if one exists.
The key of the push rule condition: a dotted field to fetch.
The matrix event to fetch the field from.
The value at the dotted path given by key.
Static
actionConvert a list of actions into a object with the actions as keys and their values
The actions list
A object with key 'notify' (true or false) and an object of actions
eg. `[ 'notify', { set_tweak: 'sound', value: 'default' } ]`
becomes `{ notify: true, tweaks: { sound: 'default' } }`
Static
partsStatic
rewriteRewrites conditions on a client's push rules to match the defaults where applicable. Useful for upgrading push rules to more strict conditions when the server is falling behind on defaults.
The client's existing push rules
The Matrix ID of the client.
The rewritten rules
Generated using TypeDoc
Construct a Push Processor.