from _typeshed import Incomplete

from kafka.protocol.abstract import AbstractType as AbstractType

class Int8(AbstractType):
    @classmethod
    def encode(cls, value): ...
    @classmethod
    def decode(cls, data): ...

class Int16(AbstractType):
    @classmethod
    def encode(cls, value): ...
    @classmethod
    def decode(cls, data): ...

class Int32(AbstractType):
    @classmethod
    def encode(cls, value): ...
    @classmethod
    def decode(cls, data): ...

class Int64(AbstractType):
    @classmethod
    def encode(cls, value): ...
    @classmethod
    def decode(cls, data): ...

class Float64(AbstractType):
    @classmethod
    def encode(cls, value): ...
    @classmethod
    def decode(cls, data): ...

class String(AbstractType):
    encoding: Incomplete
    def __init__(self, encoding: str = "utf-8") -> None: ...
    def encode(self, value): ...
    def decode(self, data): ...

class Bytes(AbstractType):
    @classmethod
    def encode(cls, value): ...
    @classmethod
    def decode(cls, data): ...
    @classmethod
    def repr(cls, value): ...

class Boolean(AbstractType):
    @classmethod
    def encode(cls, value): ...
    @classmethod
    def decode(cls, data): ...

class Schema(AbstractType):
    def __init__(self, *fields) -> None: ...
    def encode(self, item): ...
    def decode(self, data): ...
    def __len__(self) -> int: ...
    def repr(self, value): ...

class Array(AbstractType):
    array_of: Incomplete
    def __init__(self, *array_of) -> None: ...
    def encode(self, items): ...
    def decode(self, data): ...
    def repr(self, list_of_items): ...

class UnsignedVarInt32(AbstractType):
    @classmethod
    def decode(cls, data): ...
    @classmethod
    def encode(cls, value): ...

class VarInt32(AbstractType):
    @classmethod
    def decode(cls, data): ...
    @classmethod
    def encode(cls, value): ...

class VarInt64(AbstractType):
    @classmethod
    def decode(cls, data): ...
    @classmethod
    def encode(cls, value): ...

class CompactString(String):
    def decode(self, data): ...
    def encode(self, value): ...

class TaggedFields(AbstractType):
    @classmethod
    def decode(cls, data): ...
    @classmethod
    def encode(cls, value): ...

class CompactBytes(AbstractType):
    @classmethod
    def decode(cls, data): ...
    @classmethod
    def encode(cls, value): ...

class CompactArray(Array):
    def encode(self, items): ...
    def decode(self, data): ...

class BitField(AbstractType):
    @classmethod
    def decode(cls, data): ...
    @classmethod
    def encode(cls, vals): ...
    @classmethod
    def to_32_bit_field(cls, vals): ...
    @classmethod
    def from_32_bit_field(cls, value): ...
