MCPcopy
hub / github.com/vnpy/vnpy / connect

Method connect

vnpy/trader/engine.py:234–242  ·  view source on GitHub ↗

Start connection of a specific gateway.

(self, setting: dict, gateway_name: str)

Source from the content-addressed store, hash-verified

232 return self.exchanges
233
234 def connect(self, setting: dict, gateway_name: str) -> None:
235 """
236 Start connection of a specific gateway.
237 """
238 gateway: BaseGateway | None = self.get_gateway(gateway_name)
239 if gateway:
240 self.write_log(_("连接登录 -> {}").format(gateway_name))
241
242 gateway.connect(setting)
243
244 def subscribe(self, req: SubscribeRequest, gateway_name: str) -> None:
245 """

Callers 15

run_recorderFunction · 0.95
main_terminalFunction · 0.95
run_childFunction · 0.95
add_plotMethod · 0.45
_connect_signalMethod · 0.45
init_dockMethod · 0.45
init_menuMethod · 0.45
add_actionMethod · 0.45
init_menuMethod · 0.45
register_eventMethod · 0.45
init_uiMethod · 0.45
init_uiMethod · 0.45

Calls 2

get_gatewayMethod · 0.95
write_logMethod · 0.95

Tested by

no test coverage detected