def __init__(self, in_port, callback_entrance=None, binding_instance=None):
		'''指定输入端口号,整数
		指定回调函数入口
		指定持有这个端口的实例
		'''
		super(tcp_gateway, self).__init__(binding_instance)
		
		platform_category=binding_instance._environment_pack['current_platform_info']['current_system_category']
		self.lan_ip=get_local_ip(platform_category)
		self.listening_port=in_port
		if callback_entrance:
			self.listener=tcp_intrance(in_port, callback_entrance)
		pass
Beispiel #2
0
    def __init__(self, in_port, callback_entrance=None, binding_instance=None):
        '''指定输入端口号,整数
		指定回调函数入口
		指定持有这个端口的实例
		'''
        super(zmq_io_gateway, self).__init__(binding_instance)
        self.sender = zmq_send_connection()
        platform_category = binding_instance._environment_pack[
            'current_platform_info']['current_system_category']
        self.lan_ip = get_local_ip(platform_category)

        if callback_entrance:
            self.listener = zmq_listen_connection(in_port, callback_entrance)
        pass
Beispiel #3
0
	def __init__(self,in_port,callback_entrance=None,binding_instance=None):
		'''指定输入端口号,整数
		指定回调函数入口
		指定持有这个端口的实例
		'''
		super(zmq_io_gateway, self).__init__(binding_instance)
		
		
		self.sender=zmq_send_connection()
		
		platform_category=binding_instance._environment_pack['current_platform_info']['current_system_category']
		self.lan_ip=get_local_ip(platform_category)

		if callback_entrance:
			self.listener=zmq_listen_connection(in_port,callback_entrance)
		pass