Mercurial > libervia-pubsub
view idavoll/disco.py @ 153:753b8432460f
Work towards JEP-0060 1.8
- Remove subscription information from <affiliations/> result.
- Add handling of <subscriptions/> entity use case.
- Make <subscribe/> return <subscription/> instead of <entity/>.
- Move <purge/> and <delete/> to owner namespace.
- Don't use 'self' in interfaces.
author | Ralph Meijer <ralphm@ik.nu> |
---|---|
date | Sat, 06 May 2006 19:47:53 +0000 |
parents | ea8b4189ae3b |
children | 5191ba7c4df8 |
line wrap: on
line source
from twisted.words.xish import domish NS = 'http://jabber.org/protocol/disco' NS_INFO = NS + '#info' NS_ITEMS = NS + '#items' class Feature(domish.Element): def __init__(self, feature): domish.Element.__init__(self, (NS_INFO, 'feature'), attribs={'var': feature}) class Identity(domish.Element): def __init__(self, category, type, name = None): domish.Element.__init__(self, (NS_INFO, 'identity'), attribs={'category': category, 'type': type}) if name: self['name'] = name class Item(domish.Element): def __init__(self, jid, node = None, name = None): domish.Element.__init__(self, (NS_ITEMS, 'item'), attribs={'jid': jid}) if node: self['node'] = node if name: self['name'] = name