diff options
author | Nathan Fritz <nathan@andyet.net> | 2010-04-22 21:24:28 -0700 |
---|---|---|
committer | Nathan Fritz <nathan@andyet.net> | 2010-04-22 21:24:28 -0700 |
commit | 602a6d8491171de5cccb332684813e71f5d33c43 (patch) | |
tree | dfdc53119b3c28ec0d5ec61eb47ebf515d6fcd77 /sleekxmpp/plugins/stanza_pubsub.py | |
parent | 37b571c55ab00b3107a480027f0ba212831bf7ed (diff) | |
download | slixmpp-602a6d8491171de5cccb332684813e71f5d33c43.tar.gz slixmpp-602a6d8491171de5cccb332684813e71f5d33c43.tar.bz2 slixmpp-602a6d8491171de5cccb332684813e71f5d33c43.tar.xz slixmpp-602a6d8491171de5cccb332684813e71f5d33c43.zip |
bugfixes and continuing to work on pubsub tests
Diffstat (limited to 'sleekxmpp/plugins/stanza_pubsub.py')
-rw-r--r-- | sleekxmpp/plugins/stanza_pubsub.py | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/sleekxmpp/plugins/stanza_pubsub.py b/sleekxmpp/plugins/stanza_pubsub.py index 6ed84f1e..4187d49c 100644 --- a/sleekxmpp/plugins/stanza_pubsub.py +++ b/sleekxmpp/plugins/stanza_pubsub.py @@ -81,39 +81,6 @@ class Subscriptions(ElementBase): plugin_tag_map = {} subitem = (Subscription,) - def __init__(self, *args, **kwargs): - ElementBase.__init__(self, *args, **kwargs) - self.subscriptions = [] - self.idx = 0 - - def __iter__(self): - self.idx = 0 - return self - - def __next__(self): - self.idx += 1 - if self.idx + 1 > len(self.subscriptions): - self.idx = 0 - raise StopIteration - return self.subscriptions[self.idx] - - def __len__(self): - return len(self.subscriptions) - - def append(self, subscription): - if not isinstance(subscription, Subscription): - raise TypeError - self.xml.append(subscription.xml) - return self.subscriptions.append(subscription) - - def pop(self, idx=0): - aff = self.subscriptions.pop(idx) - self.xml.remove(aff.xml) - return aff - - def find(self, subscription): - return self.subscriptions.find(subscription) - stanzaPlugin(Pubsub, Subscriptions) class OptionalSetting(object): |