plugin groupblog: subscriptions/notifications
This commit is contained in:
parent
41605b1425
commit
357374bcd2
2 changed files with 101 additions and 6 deletions
|
|
@ -34,6 +34,9 @@ const_OBJ_PATH = '/org/goffi/SAT/bridge'
|
|||
const_CORE_SUFFIX = ".core"
|
||||
const_PLUGIN_SUFFIX = ".plugin"
|
||||
|
||||
class ParseError(Exception):
|
||||
pass
|
||||
|
||||
class MethodNotRegistered(dbus.DBusException):
|
||||
_dbus_error_name = const_ERROR_PREFIX + ".MethodNotRegistered"
|
||||
|
||||
|
|
@ -50,7 +53,7 @@ class GenericException(dbus.DBusException):
|
|||
def __init__(self, twisted_error):
|
||||
super(GenericException,self).__init__()
|
||||
mess = twisted_error.getErrorMessage()
|
||||
self._dbus_error_name = const_ERROR_PREFIX+"."+ (mess or str(err.__class__))
|
||||
self._dbus_error_name = const_ERROR_PREFIX+"."+ (mess or str(twisted_error.__class__))
|
||||
|
||||
class DbusObject(dbus.service.Object):
|
||||
|
||||
|
|
|
|||
|
|
@ -145,6 +145,12 @@ class DBusBridgeFrontend(BridgeFrontend):
|
|||
def getMassiveLastGroupBlogs(self, publishers_type, publishers, max_items=10, profile_key='@DEFAULT@', callback=None, errback=None):
|
||||
return self.db_plugin_iface.getMassiveLastGroupBlogs(publishers_type, publishers, max_items, profile_key, reply_handler=callback, error_handler=errback)
|
||||
|
||||
def subscribeGroupBlog(self, jid, profile_key='@DEFAULT@', callback=None, errback=None):
|
||||
return self.db_plugin_iface.subscribeGroupBlog(jid, profile_key, reply_handler=callback, error_handler=errback)
|
||||
|
||||
def massiveSubscribeGroupBlogs(self, publishers_type, publishers, profile_key='@DEFAULT@', callback=None, errback=None):
|
||||
return self.db_plugin_iface.massiveSubscribeGroupBlogs(publishers_type, publishers, profile_key, reply_handler=callback, error_handler=errback)
|
||||
|
||||
def sendPersonalEvent(self, event_type, data, profile_key):
|
||||
return self.db_plugin_iface.sendPersonalEvent(event_type, data, profile_key)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue