StanzaHandler class

A Handler that only matches stanzas.

Inheritance

Constructors

StanzaHandler({required Future<StanzaHandlerData> callback(Stanza, StanzaHandlerData), String? tagXmlns, String? tagName, int priority = 0, String? stanzaTag, String? xmlns})

Properties

callback → Future<StanzaHandlerData> Function(Stanza, StanzaHandlerData)
The function to call when a stanza matches the description.
final
hashCode → int
The hash code for this object.
no setterinherited
priority → int
The priority after which StanzaHandlers are sorted.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
stanzaTag → String?
If specified, the matching stanza must have a tag equal to stanzaTag.
final
tagName → String?
If specified, then the stanza must contain a direct child with a tag equal to tagName.
final
tagXmlns → String?
If specified, then the stanza must contain a direct child with a xmlns attribute equal to tagXmlns. If tagName is also non-null, then the element must also have a tag equal to tagName.
final
xmlns → String?
If specified, then the stanza must have a xmlns attribute equal to xmlns. This defaults to stanzaXmlns, but can be set to any other value or null. This is useful, for example, for components.
final

Methods

matches(XMLNode node) → bool
Returns true if the node matches the description provided by this Handler.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited