class_docstr: Programmatic control over starting and stopping TWS/Gateway
  using IBC (https://github.com/IbcAlpha/IBC).
  
  Args:
      twsVersion (int): (required) The major version number for
          TWS or gateway.
      gateway (bool):
          * True = gateway
          * False = TWS
      tradingMode (str): 'live' or 'paper'.
      userid (str): IB account username. It is recommended to set the real
          username/password in a secured IBC config file.
      password (str): IB account password.
      twsPath (str): Path to the TWS installation folder.
          Defaults:
  
          * Linux:    ~/Jts
          * OS X:     ~/Applications
          * Windows:  C:\\Jts
      twsSettingsPath (str): Path to the TWS settings folder.
          Defaults:
  
          * Linux:     ~/Jts
          * OS X:      ~/Jts
          * Windows:   Not available
      ibcPath (str): Path to the IBC installation folder.
          Defaults:
  
          * Linux:     /opt/ibc
          * OS X:      /opt/ibc
          * Windows:   C:\\IBC
      ibcIni (str): Path to the IBC configuration file.
          Defaults:
  
          * Linux:     ~/ibc/config.ini
          * OS X:      ~/ibc/config.ini
          * Windows:   %%HOMEPATH%%\\Documents\IBC\\config.ini
      javaPath (str): Path to Java executable.
          Default is to use the Java VM included with TWS/gateway.
      fixuserid (str): FIX account user id (gateway only).
      fixpassword (str): FIX account password (gateway only).
      on2fatimeout (str): What to do if 2-factor authentication times
          out; Can be 'restart' or 'exit'.
  
  This is not intended to be run in a notebook.
  
  To use IBC on Windows, the proactor (or quamash) event loop
  must have been set:
  
  .. code-block:: python
  
      import asyncio
      asyncio.set_event_loop(asyncio.ProactorEventLoop())
  
  Example usage:
  
  .. code-block:: python
  
      ibc = IBC(976, gateway=True, tradingMode='live',
          userid='edemo', password='demouser')
      ibc.start()
      IB.run()
class_docstr_tok: ["Programmatic","control","over","starting","and","stopping","TWS\/Gateway","using","IBC","(","https",":","\/\/github.com\/IbcAlpha\/IBC",")",".","Args",":","twsVersion","(","int",")",":","(","required",")","The","major","version","number","for","TWS","or","gateway",".","gateway","(","bool",")",":","*","True","=","gateway","*","False","=","TWS","tradingMode","(","str",")",":","'live","'","or","'paper","'",".","userid","(","str",")",":","IB","account","username",".","It","is","recommended","to","set","the","real","username\/password","in","a","secured","IBC","config","file",".","password","(","str",")",":","IB","account","password",".","twsPath","(","str",")",":","Path","to","the","TWS","installation","folder",".","Defaults",":","*","Linux",":","~\/Jts","*","OS","X",":","~\/Applications","*","Windows",":","C",":","\\\\Jts","twsSettingsPath","(","str",")",":","Path","to","the","TWS","settings","folder",".","Defaults",":","*","Linux",":","~\/Jts","*","OS","X",":","~\/Jts","*","Windows",":","Not","available","ibcPath","(","str",")",":","Path","to","the","IBC","installation","folder",".","Defaults",":","*","Linux",":","\/opt\/ibc","*","OS","X",":","\/opt\/ibc","*","Windows",":","C",":","\\\\IBC","ibcIni","(","str",")",":","Path","to","the","IBC","configuration","file",".","Defaults",":","*","Linux",":","~\/ibc\/config.ini","*","OS","X",":","~\/ibc\/config.ini","*","Windows",":","%","%","HOMEPATH","%","%","\\\\Documents\\IBC\\\\config.ini","javaPath","(","str",")",":","Path","to","Java","executable",".","Default","is","to","use","the","Java","VM","included","with","TWS\/gateway",".","fixuserid","(","str",")",":","FIX","account","user","id","(","gateway","only",")",".","fixpassword","(","str",")",":","FIX","account","password","(","gateway","only",")",".","on2fatimeout","(","str",")",":","What","to","do","if","2-factor","authentication","times","out",";","Can","be","'restart","'","or","'exit","'",".","This","is","not","intended","to","be","run","in","a","notebook",".","To","use","IBC","on","Windows",",","the","proactor","(","or","quamash",")","event","loop","must","have","been","set",":","..","code-block",":",":","python","import","asyncio","asyncio.set_event_loop","(","asyncio.ProactorEventLoop","(",")",")","Example","usage",":","..","code-block",":",":","python","ibc","=","IBC","(","976",",","gateway=True",",","tradingMode='live","'",",","userid='edemo","'",",","password='demouser","'",")","ibc.start","(",")","IB.run","(",")"]
docstr: Launch TWS/IBG.
docstr_tok: ["Launch","TWS\/IBG","."]
code: def start(self):
      """Launch TWS/IBG."""
      util.run(self.startAsync())
  
file_path: ib_insync/ib_insync/ibcontroller.py
imports: import asyncio
  import logging
  import sys
  from contextlib import suppress
  from dataclasses import dataclass
  from typing import ClassVar
  from eventkit import Event
  import ib_insync.util
  from ib_insync.contract import Contract, Forex
  from ib_insync.ib import IB
label_desc: Use image node_id 4 for calling the IBC obj's underlying member method code with example usage: obj.start() without return types