# Path: telethon/_network/transports/transport.py
# class Transport(abc.ABC):
#     # Should return a newly-created instance of itself
#     @abc.abstractmethod
#     def recreate_fresh(self):
#         pass
# 
#     @abc.abstractmethod
#     def pack(self, input: bytes) -> bytes:
#         pass
# 
#     # Should raise EOFError if it does not have enough bytes
#     @abc.abstractmethod
#     def unpack(self, input: bytes) -> (int, bytes):
#         pass


from .transport import Transport
import struct


class Abridged(Transport):
    def __init__(self):
        self._init = False

    def recreate_fresh(self):
        return type(self)()

    def pack(self, input: bytes) -> bytes:
        if self._init:
            header = b''
        else:
            header = b'\xef'

# Path: telethon/_network/transports/transport.py
# class Transport(abc.ABC):
#     # Should return a newly-created instance of itself
#     @abc.abstractmethod
#     def recreate_fresh(self):
#         pass
# 
#     @abc.abstractmethod
#     def pack(self, input: bytes) -> bytes:
#         pass
# 
#     # Should raise EOFError if it does not have enough bytes
#     @abc.abstractmethod
#     def unpack(self, input: bytes) -> (int, bytes):
#         pass


# Path: telethon/_network/transports/abridged.py
from .transport import Transport
import struct



class Abridged(Transport):
    def __init__(self):
        self._init = False

    def recreate_fresh(self):
        return type(self)()

    def pack(self, input: bytes) -> bytes:
        if self._init:
            header = b''
        else:
            header = b'\xef'

            self._init = True