def __init__(self, transport, maxdata, remote_banner):
    """Create an ADB connection to a device.

    Args:
      transport: AdbTransportAdapter to use for reading/writing AdbMessages
      maxdata: Max data size the remote endpoint will accept.
      remote_banner: Banner received from the remote endpoint.
    """
    try:
      self.systemtype, self.serial, self.banner = remote_banner.split(':', 2)
    except ValueError:
      raise usb_exceptions.AdbProtocolError('Received malformed banner %s',
                                            remote_banner)
    self.transport = transport
    self.maxdata = maxdata
    self._last_id_used = 0
    self._reader_lock = threading.Lock()
    self._open_lock = threading.Lock()
    # Maps local_id: AdbStreamTransport object for the relevant stream.
    self._stream_transport_map = {}
    self._stream_transport_map_lock = threading.RLock()
def __init__ ( self , transport , maxdata , remote_banner ) : try : self . systemtype , self . serial , self . banner = remote_banner . split ( ':' , 2 ) except ValueError : raise usb_exceptions . AdbProtocolError ( 'Received malformed banner %s' , remote_banner ) self . transport = transport self . maxdata = maxdata self . _last_id_used = 0 self . _reader_lock = threading . Lock ( ) self . _open_lock = threading . Lock ( ) self . _stream_transport_map = { } self . _stream_transport_map_lock = threading . RLock ( )
Create an ADB connection to a device.

    Args:
      transport: AdbTransportAdapter to use for reading/writing AdbMessages
      maxdata: Max data size the remote endpoint will accept.
      remote_banner: Banner received from the remote endpoint.