| | |
| | | self.call_back_thread_pool = concurrent.futures.ThreadPoolExecutor(max_workers=10) |
| | | |
| | | def OnFrontConnected(self) -> "void": |
| | | print("OnFrontConnected") |
| | | |
| | | # 获取终端信息 |
| | | TradeSimpleApi.req_id += 1 |
| | |
| | | |
| | | def OnRspGetConnectionInfo(self, pConnectionInfoField: "CTORATstpConnectionInfoField", |
| | | pRspInfoField: "CTORATstpRspInfoField", nRequestID: "int") -> "void": |
| | | print("OnRspGetConnectionInfo") |
| | | if pRspInfoField.ErrorID == 0: |
| | | logger.info('inner_ip_address[%s]' % pConnectionInfoField.InnerIPAddress) |
| | | logger.info('inner_port[%d]' % pConnectionInfoField.InnerPort) |
| | |
| | | |
| | | def OnRspUserLogin(self, pRspUserLoginField: "CTORATstpRspUserLoginField", pRspInfoField: "CTORATstpRspInfoField", |
| | | nRequestID: "int") -> "void": |
| | | print("OnRspUserLogin") |
| | | if pRspInfoField.ErrorID == 0: |
| | | logger_system.info('Login success! [%d]' % nRequestID) |
| | | self.__front_id = pRspUserLoginField.FrontID |