Implement fromhex and maketrans method

This commit is contained in:
Ismail
2016-01-25 15:43:06 +00:00
parent 2c4549fb36
commit fd4d063bb4

View File

@@ -295,8 +295,10 @@ class bytes(ByteString):
def translate(self, table: bytes) -> bytes: ...
def upper(self) -> bytes: ...
def zfill(self, width: int) -> bytes: ...
# TODO fromhex
# TODO maketrans
@classmethod
def fromhex(cls, s: str) -> bytes: ...
@classmethod
def maketrans(cls, frm: ByteString, to: ByteString) -> bytes: ...
def __len__(self) -> int: ...
def __iter__(self) -> Iterator[int]: ...
@@ -366,8 +368,10 @@ class bytearray(MutableSequence[int], ByteString):
def translate(self, table: bytes) -> bytearray: ...
def upper(self) -> bytearray: ...
def zfill(self, width: int) -> bytearray: ...
# TODO fromhex
# TODO maketrans
@classmethod
def fromhex(cls, s: str) -> bytearray: ...
@classmethod
def maketrans(cls, frm: ByteString, to: ByteString) -> bytes: ...
def __len__(self) -> int: ...
def __iter__(self) -> Iterator[int]: ...