def __init__(self, protocol, manager, parameters): protocol.check_parameters(parameters) self._manager = weakref.proxy(manager) account = 'acc' self._statuses = protocol._statuses self._channel_manager = DictionaryChannelManager(self, protocol) self._account = ( parameters['server'].encode('utf-8'), parameters['port'], ) Connection.__init__(self, PROTOCOL, account, PROGRAM, protocol) ConnectionInterfaceContactGroups.__init__(self) ConnectionInterfaceContactList.__init__(self) ConnectionInterfaceContacts.__init__(self) ConnectionInterfaceRequests.__init__(self) ConnectionInterfaceSimplePresence.__init__(self) self_handle = self.create_handle(HANDLE_TYPE_CONTACT, account.encode('utf-8')) self.set_self_handle(self_handle) self._tn = None self.__disconnect_reason = CONNECTION_STATUS_REASON_NONE_SPECIFIED
def __init__(self, manager, parameters): self._manager = weakref.proxy(manager) # create a new channel manager and tell it we're it's connection self._channel_manager = caveChannelManager(self) # assume we have an 'account' name passed to us Connection.__init__(self, PROTOCOL, parameters["account"], PROGRAM) ConnectionInterfaceRequests.__init__(self) caveContacts.__init__(self) self._self_handle = Handle(self.get_handle_id(), HANDLE_TYPE_CONTACT, parameters["account"]) self._handles[HANDLE_TYPE_CONTACT, self._self_handle.get_id()] = self._self_handle
def __init__(self, protocol, manager, parameters): # self.account = parameters['account'].encode('utf-8') self._manager = weakref.proxy(manager) logger.debug('VkMessenger') VkMessenger.__init__(self, CLIENT_ID, CLIENT_SECRET, CLIENT_SCOPE) logger.debug('login') self.parameters = parameters self.alias_is_screen_name = parameters.get('alias is screen_name') #contact = self.contact_list.get(None) account = escape_as_dbus_path(parameters.get( 'account', 'vkconnection')) # str(contact.get('id')) # create a new channel manager and tell it we're it's connection self._channel_manager = vkChannelManager(self) Connection.__init__(self, PROTOCOL, account, PROGRAM) ConnectionInterfaceRequests.__init__(self) vkContacts.__init__(self)
def __init__(self, protocol, manager, parameters): protocol.check_parameters(parameters) self._manager = weakref.proxy(manager) account = unicode(parameters['account']) self._statuses = protocol._statuses self._supported_avatar_mime_types = protocol._supported_avatar_mime_types self._channel_manager = FooChannelManager(self, protocol) Connection.__init__(self, PROTOCOL, account, PROGRAM, protocol) ConnectionInterfaceAliasing.__init__(self) ConnectionInterfaceAvatars.__init__(self) ConnectionInterfaceBalance.__init__(self) ConnectionInterfaceContactGroups.__init__(self) ConnectionInterfaceContactInfo.__init__(self) ConnectionInterfaceContactList.__init__(self) ConnectionInterfaceContacts.__init__(self) ConnectionInterfaceRequests.__init__(self) ConnectionInterfaceSimplePresence.__init__(self) self_handle = self.create_handle(HANDLE_TYPE_CONTACT, account.encode('utf-8')) self.set_self_handle(self_handle) self.__disconnect_reason = CONNECTION_STATUS_REASON_NONE_SPECIFIED
def __init__(self,protocol,manager, parameters): # self.account = parameters['account'].encode('utf-8') self._manager = weakref.proxy(manager) logger.debug('VkMessenger') VkMessenger.__init__(self, CLIENT_ID, CLIENT_SECRET, CLIENT_SCOPE) logger.debug('login') self.parameters = parameters self.alias_is_screen_name = parameters.get('alias is screen_name') #contact = self.contact_list.get(None) account = escape_as_dbus_path(parameters.get('account','vkconnection') )# str(contact.get('id')) # create a new channel manager and tell it we're it's connection self._channel_manager = vkChannelManager(self) Connection.__init__(self, PROTOCOL, account, PROGRAM) ConnectionInterfaceRequests.__init__(self) vkContacts.__init__(self)
def __init__(self, protocol, manager, parameters): protocol.check_parameters(parameters) self._manager = weakref.proxy(manager) account = unicode(parameters['account']) self._statuses = protocol._statuses self._channel_manager = SkykitChannelManager(self, protocol) self._account = ( parameters['account'].encode('utf-8'), parameters['password'].encode('utf-8'), ) Connection.__init__(self, PROTOCOL, account, PROGRAM, protocol) ConnectionInterfaceAliasing.__init__(self) ConnectionInterfaceAvatars.__init__(self) ConnectionInterfaceContactGroups.__init__(self) ConnectionInterfaceContactInfo.__init__(self) ConnectionInterfaceContactList.__init__(self) ConnectionInterfaceContacts.__init__(self) ConnectionInterfaceRequests.__init__(self) ConnectionInterfaceSimplePresence.__init__(self) self_handle = self.ensure_handle(HANDLE_TYPE_CONTACT, self._account[0]) self.set_self_handle(self_handle) self._skype = Skype.GetSkype(SKYPEKITKEY) self._skype.Start() self._skype_account = self._skype.GetAccount(self._account[0].decode('utf-8')) Skype.Account.OnPropertyChange = self.OnPropertyChange Skype.Contact.OnPropertyChange = self.ContactOnPropertyChange Skype.Skype.OnConversationListChange = self.OnConversationListChange Skype.Skype.OnMessage = self.OnMessage Skype.Skype.OnContactOnlineAppearance = self.OnContactOnlineAppearance Skype.Skype.OnContactGoneOffline = self.OnContactGoneOffline self.__disconnect_reason = CONNECTION_STATUS_REASON_NONE_SPECIFIED