MCPcopy Index your code
hub / github.com/aws/aws-cli / encode

Method encode

awscli/customizations/emrcontainers/base36.py:24–33  ·  view source on GitHub ↗

Method to return base36 encoded form of the input string

(self, request)

Source from the content-addressed store, hash-verified

22 return result
23
24 def encode(self, request):
25 """Method to return base36 encoded form of the input string"""
26 decimal_number = self.str_to_int(str(request))
27 alphabet, base36 = ['0123456789abcdefghijklmnopqrstuvwxyz', '']
28
29 while decimal_number:
30 decimal_number, i = divmod(decimal_number, 36)
31 base36 = alphabet[i] + base36
32
33 return base36 or alphabet[0]

Callers 15

__call__Method · 0.45
uni_printFunction · 0.45
__init__Method · 0.45
get_tokenMethod · 0.45
_get_private_pemMethod · 0.45
_convert_path_argsMethod · 0.45

Calls 1

str_to_intMethod · 0.95

Tested by

no test coverage detected