Mercurial > libervia-pubsub
comparison sat_pubsub/tap.py @ 280:798cb8962c0b
MAM (XEP-0313) support: first draft
author | souliane <souliane@mailoo.org> |
---|---|
date | Fri, 09 Jan 2015 10:57:10 +0100 |
parents | 8a71486c3e95 |
children | 30895c49ebd2 |
comparison
equal
deleted
inserted
replaced
279:7c820a8e4b00 | 280:798cb8962c0b |
---|---|
63 from wokkel import pubsub, rsm | 63 from wokkel import pubsub, rsm |
64 | 64 |
65 from sat_pubsub import __version__, const | 65 from sat_pubsub import __version__, const |
66 from sat_pubsub.backend import BackendService | 66 from sat_pubsub.backend import BackendService |
67 from sat_pubsub.remote_roster import RosterClient | 67 from sat_pubsub.remote_roster import RosterClient |
68 | |
68 | 69 |
69 class Options(usage.Options): | 70 class Options(usage.Options): |
70 optParameters = [ | 71 optParameters = [ |
71 ('jid', None, 'pubsub', 'JID this component will be available at'), | 72 ('jid', None, 'pubsub', 'JID this component will be available at'), |
72 ('secret', None, 'secret', 'Jabber server component secret'), | 73 ('secret', None, 'secret', 'Jabber server component secret'), |
147 | 148 |
148 rc = RosterClient() | 149 rc = RosterClient() |
149 rc.setHandlerParent(cs) | 150 rc.setHandlerParent(cs) |
150 bs.roster = rc | 151 bs.roster = rc |
151 | 152 |
153 if const.FLAG_ENABLE_MAM: | |
154 mam_resource = MAMResource() | |
155 mam_s = mam.MAMService(mam_resource) | |
156 mam_s.setHandlerParent(cs) | |
157 | |
152 return s | 158 return s |