comparison sat/core/xmpp.py @ 2778:f7deb1c36b47

core, XEP-0315: move XML element handling to sat_tmp: XML Element is now implemented in sat_tmp, so it can be available also for SàT Pubsub. The XEP-0315 is thus not needed anymore and have been removed, XEP-0315 namespace has been added to base disco features. Use the new install() function of sat_tmp to do the patching.
author Goffi <goffi@goffi.org>
date Wed, 16 Jan 2019 09:18:16 +0100
parents 003b8b4b56a7
children 33fa70c102de
comparison
equal deleted inserted replaced
2777:ff1b40823b07 2778:f7deb1c36b47
43 import sys 43 import sys
44 44
45 45
46 NS_X_DATA = u"jabber:x:data" 46 NS_X_DATA = u"jabber:x:data"
47 NS_DISCO_INFO = u"http://jabber.org/protocol/disco#info" 47 NS_DISCO_INFO = u"http://jabber.org/protocol/disco#info"
48 NS_XML_ELEMENT = u"urn:xmpp:xml-element"
48 49
49 50
50 class SatXMPPEntity(object): 51 class SatXMPPEntity(object):
51 """Common code for Client and Component""" 52 """Common code for Client and Component"""
52 53
1391 1392
1392 def __init__(self, host): 1393 def __init__(self, host):
1393 disco.DiscoClientProtocol.__init__(self) 1394 disco.DiscoClientProtocol.__init__(self)
1394 1395
1395 def getDiscoInfo(self, requestor, target, nodeIdentifier=""): 1396 def getDiscoInfo(self, requestor, target, nodeIdentifier=""):
1397 # those features are implemented in Wokkel (or sat_tmp.wokkel)
1398 # and thus are always available
1396 return [disco.DiscoFeature(NS_X_DATA), 1399 return [disco.DiscoFeature(NS_X_DATA),
1400 disco.DiscoFeature(NS_XML_ELEMENT),
1397 disco.DiscoFeature(NS_DISCO_INFO)] 1401 disco.DiscoFeature(NS_DISCO_INFO)]
1398 1402
1399 def getDiscoItems(self, requestor, target, nodeIdentifier=""): 1403 def getDiscoItems(self, requestor, target, nodeIdentifier=""):
1400 return [] 1404 return []
1401 1405