Move XEP-0203 to new system.
This commit is contained in:
parent
6497857495
commit
4a009515c1
@ -6,7 +6,16 @@
|
|||||||
See the file LICENSE for copying permission.
|
See the file LICENSE for copying permission.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
from sleekxmpp.plugins.base import register_plugin
|
||||||
|
|
||||||
from sleekxmpp.plugins.xep_0203 import stanza
|
from sleekxmpp.plugins.xep_0203 import stanza
|
||||||
from sleekxmpp.plugins.xep_0203.stanza import Delay
|
from sleekxmpp.plugins.xep_0203.stanza import Delay
|
||||||
from sleekxmpp.plugins.xep_0203.delay import xep_0203
|
from sleekxmpp.plugins.xep_0203.delay import XEP_0203
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
register_plugin(XEP_0203)
|
||||||
|
|
||||||
|
|
||||||
|
# Retain some backwards compatibility
|
||||||
|
xep_0203 = XEP_0203
|
||||||
|
@ -9,11 +9,11 @@
|
|||||||
|
|
||||||
from sleekxmpp.stanza import Message, Presence
|
from sleekxmpp.stanza import Message, Presence
|
||||||
from sleekxmpp.xmlstream import register_stanza_plugin
|
from sleekxmpp.xmlstream import register_stanza_plugin
|
||||||
from sleekxmpp.plugins.base import base_plugin
|
from sleekxmpp.plugins import BasePlugin
|
||||||
from sleekxmpp.plugins.xep_0203 import stanza
|
from sleekxmpp.plugins.xep_0203 import stanza
|
||||||
|
|
||||||
|
|
||||||
class xep_0203(base_plugin):
|
class XEP_0203(BasePlugin):
|
||||||
|
|
||||||
"""
|
"""
|
||||||
XEP-0203: Delayed Delivery
|
XEP-0203: Delayed Delivery
|
||||||
@ -26,11 +26,12 @@ class xep_0203(base_plugin):
|
|||||||
Also see <http://www.xmpp.org/extensions/xep-0203.html>.
|
Also see <http://www.xmpp.org/extensions/xep-0203.html>.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
name = 'xep_0203'
|
||||||
|
description = 'XEP-0203: Delayed Delivery'
|
||||||
|
dependencies = set()
|
||||||
|
stanza = stanza
|
||||||
|
|
||||||
def plugin_init(self):
|
def plugin_init(self):
|
||||||
"""Start the XEP-0203 plugin."""
|
"""Start the XEP-0203 plugin."""
|
||||||
self.xep = '0203'
|
|
||||||
self.description = 'Delayed Delivery'
|
|
||||||
self.stanza = stanza
|
|
||||||
|
|
||||||
register_stanza_plugin(Message, stanza.Delay)
|
register_stanza_plugin(Message, stanza.Delay)
|
||||||
register_stanza_plugin(Presence, stanza.Delay)
|
register_stanza_plugin(Presence, stanza.Delay)
|
||||||
|
Loading…
Reference in New Issue
Block a user