code: def with_config(loop=None):
      
      cfg = _Config()
      if loop is not None:
          cfg.loop = loop
      return _AsyncioApi(cfg)
docs: :return: an instance of the txaio API with the given
          configuration. This won't affect anything using the 'gloabl'
          config nor other instances created using this function.
  
      If you need to customize txaio configuration separately (e.g. to
      use multiple event-loops in asyncio), you can take code like this:
  
          import txaio
  
  
          class FunTimes(object):
  
              def something_async(self):
                  return txaio.call_later(1, lambda: 'some result')
  
      and instead do this:
  
          import txaio
  
  
          class FunTimes(object):
              txaio = txaio
  
              def something_async(self):
                  # this will run in the local/new event loop created in the constructor
                  return self.txaio.call_later(1, lambda: 'some result')
  
          fun0 = FunTimes()
          fun1 = FunTimes()
          fun1.txaio = txaio.with_config(loop=asyncio.new_event_loop())
  
      So `fun1` will run its futures on the newly-created event loop,
      while `fun0` will work just as it did before this `with_config`
      method was introduced (after 2.6.2).