|
| 1 | +import sys |
| 2 | +from _typeshed import ReadableBuffer |
| 3 | + |
| 4 | +if sys.version_info < (3,): |
| 5 | + from hashlib import _hash as _Hash |
| 6 | +else: |
| 7 | + from hashlib import _Hash |
| 8 | + |
| 9 | +VERSION: str |
| 10 | +XXHASH_VERSION: str |
| 11 | + |
| 12 | +class _IntDigestHash(_Hash): |
| 13 | + def __init__(self, __string: ReadableBuffer = ...): ... |
| 14 | + def intdigest(self) -> int: ... |
| 15 | + |
| 16 | +# python-xxhash v2.0.0 does not support the string or usedforsecurity kwargs |
| 17 | +class xxh32(_IntDigestHash): ... |
| 18 | +class xxh64(_IntDigestHash): ... |
| 19 | +class xxh3_64(_IntDigestHash): ... |
| 20 | +class xxh3_128(_IntDigestHash): ... |
| 21 | + |
| 22 | +def xxh32_digest(input: ReadableBuffer = ...) -> bytes: ... |
| 23 | +def xxh32_intdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 24 | +def xxh32_hexdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 25 | +def xxh64_digest(input: ReadableBuffer = ...) -> bytes: ... |
| 26 | +def xxh64_intdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 27 | +def xxh64_hexdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 28 | +def xxh3_64_digest(input: ReadableBuffer = ...) -> bytes: ... |
| 29 | +def xxh3_64_intdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 30 | +def xxh3_64_hexdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 31 | +def xxh3_128_digest(input: ReadableBuffer = ...) -> bytes: ... |
| 32 | +def xxh3_128_intdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 33 | +def xxh3_128_hexdigest(input: ReadableBuffer = ...) -> bytes: ... |
| 34 | + |
| 35 | +xxh128 = xxh3_128 |
| 36 | +xxh128_digest = xxh3_128_digest |
| 37 | +xxh128_intdigest = xxh3_128_intdigest |
| 38 | +xxh128_hexdigest = xxh3_128_hexdigest |
0 commit comments