VccsdZddlZddlZddZddZGddejZGdd ejZGd d ejZGd d eejZGddeej Z dZ dS)zPython 'hex_codec' Codec - 2-digit hex content transfer encoding. This codec de/encodes from bytes to bytes. Written by Marc-Andre Lemburg (mal@lemburg.com). iNstrictcX|dksJtj|t|fSNr)binasciib2a_hexleninputerrors ,/usr/lib64/python3.11/encodings/hex_codec.py hex_encoder / X   U # #SZZ 00crr)ra2b_hexrrr r hex_decoderr r cseZdZddZddZdS)Codecrc"t||SN)r selfrr r encodez Codec.encode%(((r crr)rrrr decodez Codec.decoderr Nr)__name__ __module__ __qualname__rrr r rrs<))))))))))r rceZdZddZdS)IncrementalEncoderFcD|jdksJtj|Sr)rrrrrZfinalrr rzIncrementalEncoder.encode&{h&&&&&&&r NF)rrrrrr r rr(''''''r rcr)IncrementalDecoderFcr r)rrrr!rr rzIncrementalDecoder.decode!r"r Nr#)rrrrrr r r%r% r$r r%ceZdZeZdS) StreamWriterNrrrZbytesZcharbuffertyperr r r'r'%NNNr r'cr&) StreamReaderNr(rr r r*r*(r)r r*c svtjdtttt t tdS)NZhexF)ZnamerrZincrementalencoderZincrementaldecoderZ streamwriterZ streamreaderZ_is_text_encoding)codecsZ CodecInfor rrr%r'r*rr r getregentryr,-s4   --!!    r r) Z__doc__r+rr rrrr%r'r*r,rr r r-sH 11111111)))))FL))) '''''2''' '''''2''' 5&-5&-     r