1 # -*- coding: utf-8 -*-
3 sleekxmpp.xmlstream.matcher.base
4 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
6 Part of SleekXMPP: The Sleek XMPP Library
8 :copyright: (c) 2011 Nathanael C. Fritz
9 :license: MIT, see LICENSE for more details
13 class MatcherBase(object):
16 Base class for stanza matchers. Stanza matchers are used to pick
17 stanzas out of the XML stream and pass them to the appropriate
20 :param criteria: Object to compare some aspect of a stanza against.
23 def __init__(self
, criteria
):
24 self
._criteria
= criteria
27 """Check if a stanza matches the stored criteria.
29 Meant to be overridden.