Browse Source

Transport: mark abstract methods with @abc.abstractmethod

master
Vadim Yanitskiy 2 months ago
parent
commit
f9759d1024
  1. 4
      transport.py

4
transport.py

@ -30,15 +30,19 @@ class TransportIOError(Exception):
class Transport(abc.ABC):
''' Abstract transport layer for DebugMux '''
@abc.abstractmethod
def connect(self, opts: dict) -> None:
''' Establish connection to the target and enter DebugMux mode '''
@abc.abstractmethod
def disconnect(self) -> None:
''' Escape DebugMux mode and terminate connection with the target '''
@abc.abstractmethod
def write(self, data: bytes) -> int:
''' Write the given data bytes '''
@abc.abstractmethod
def read(self, length: int = 0) -> bytes:
''' Read the given number of bytes '''

Loading…
Cancel
Save