def get_event_loop():
 ev = _state.event_loop
 if ((not os.getenv(_EVENT_LOOP_KEY)) and (ev is not None)):
  ev.clear()
  _state.event_loop = None
  ev = None
 if (ev is None):
  ev = EventLoop()
  _state.event_loop = ev
  os.environ[_EVENT_LOOP_KEY] = '1'
 return ev

def get_event_loop ( ) : ev = _state . event_loop if ( ( not os . getenv ( _EVENT_LOOP_KEY ) ) and ( ev is not None ) ) : ev . clear ( ) _state . event_loop = None ev = None if ( ev is None ) : ev = EventLoop ( ) _state . event_loop = ev os . environ [ _EVENT_LOOP_KEY ] = '1' return ev
get current event loop object .