    def terminate(self):
        '''
        @brief: 不再使用通讯器需调用此函数释放资源
        '''
        tarsLogger.debug('Communicator:terminate')

        if not self.__initialize:
            return

        self.__reactor.terminate()
        self.__qTimeout.terminate()
        self.__asyncProc.terminate()

        for objName in self.__servants:
            self.__servants[objName]._terminate()

        for objName in self.__objects:
            self.__objects[objName].terminate()

        self.__objects = {}
        self.__servants = {}
        self.__reactor = None
        self.__initialize = False
@brief: 不再使用通讯器需调用此函数释放资源
biliup/Danmaku/tars/__rpc.py