client.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:caproto 作者: NSLS-II 项目源码 文件源码
def __init__(self, *, log_level='ERROR'):
        self.log_level = log_level
        self.udp_sock = None
        self._search_lock = threading.RLock()

        self.search_results = {}  # map name to (time, address)
        self.unanswered_searches = {}  # map search id (cid) to name

        self.listeners = weakref.WeakSet()

        self.broadcaster = ca.Broadcaster(our_role=ca.CLIENT)
        self.broadcaster.log.setLevel(self.log_level)
        self.command_bundle_queue = queue.Queue()
        self.command_cond = threading.Condition()

        self.selector = SelectorThread()
        self.command_thread = threading.Thread(target=self.command_loop,
                                               daemon=True)
        self.command_thread.start()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号