XEP-0428: Fallback Indication
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
"""
|
||||
Slixmpp: The Slick XMPP Library
|
||||
Copyright (C) 2020 Mathieu Pasquet <mathieui@mathieui.net>
|
||||
This file is part of Slixmpp.
|
||||
|
||||
See the file LICENSE for copying permission.
|
||||
"""
|
||||
|
||||
from slixmpp.plugins.base import register_plugin
|
||||
from slixmpp.plugins.xep_0428.stanza import *
|
||||
from slixmpp.plugins.xep_0428.fallback import XEP_0428
|
||||
|
||||
register_plugin(XEP_0428)
|
||||
@@ -0,0 +1,22 @@
|
||||
"""
|
||||
Slixmpp: The Slick XMPP Library
|
||||
Copyright (C) 2020 Mathieu Pasquet <mathieui@mathieui.net>
|
||||
This file is part of Slixmpp.
|
||||
|
||||
See the file LICENSE for copying permission.
|
||||
"""
|
||||
from slixmpp.plugins import BasePlugin
|
||||
from slixmpp.plugins.xep_0428 import stanza
|
||||
|
||||
|
||||
class XEP_0428(BasePlugin):
|
||||
'''XEP-0428: Fallback Indication'''
|
||||
|
||||
name = 'xep_0428'
|
||||
description = 'Fallback Indication'
|
||||
dependencies = set()
|
||||
stanza = stanza
|
||||
namespace = stanza.NS
|
||||
|
||||
def plugin_init(self) -> None:
|
||||
stanza.register_plugins()
|
||||
@@ -0,0 +1,26 @@
|
||||
"""
|
||||
Slixmpp: The Slick XMPP Library
|
||||
Copyright (C) 2020 Mathieu Pasquet <mathieui@mathieui.net>
|
||||
This file is part of Slixmpp.
|
||||
|
||||
See the file LICENSE for copying permissio
|
||||
"""
|
||||
|
||||
from slixmpp.stanza import Message
|
||||
from slixmpp.xmlstream import (
|
||||
ElementBase,
|
||||
register_stanza_plugin,
|
||||
)
|
||||
|
||||
|
||||
NS = 'urn:xmpp:fallback:0'
|
||||
|
||||
|
||||
class Fallback(ElementBase):
|
||||
namespace = NS
|
||||
name = 'fallback'
|
||||
plugin_attrib = 'fallback'
|
||||
|
||||
|
||||
def register_plugins():
|
||||
register_stanza_plugin(Message, Fallback)
|
||||
Reference in New Issue
Block a user