Changes

Jump to: navigation, search

Proxy

248 bytes added, 16:39, 18 January 2007
no edit summary
daemon.connect(self) # will also set self.daemon...
uri = self.NS.resolve(Pyro.constants.EVENTSERVER_NAME)
// creates a proxy for the remote class
self.eventservice=Pyro.core.getProxyForURI(uri)
self.eventservice._setIdentification(ident)
# Subscribe to one or more subjects.
# It is safe to call this multiple times.
// gets a proxy for the service
self.eventservice.subscribe(subjects, self.getProxy())
def subscribeMatch(self,subjectPatterns):
# Subscribe to one or more subjects (by pattern)
# It is safe to call this multiple times.
// gets a proxy for the service
self.eventservice.subscribeMatch(subjectPatterns, self.getProxy())
def unsubscribe(self, subjects):
# Unsubscribe the subscriber for the given subject(s).
// gets a proxy for the service
self.eventservice.unsubscribe(subjects, self.getProxy())
ns = locator.getNS(host=Pyro.config.PYRO_NS_HOSTNAME)
uri = ns.resolve(Pyro.constants.EVENTSERVER_NAME)
// gets a proxy for the service
self.eventservice=Pyro.core.getProxyForURI(uri)
self.eventservice._setIdentification(ident)
1
edit

Navigation menu