MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / encode

Method encode

tools/python-3.11.9-amd64/Lib/codecs.py:138–155  ·  view source on GitHub ↗

Encodes the object input and returns a tuple (output object, length consumed). errors defines the error handling to apply. It defaults to 'strict' handling. The method may not store state in the Codec instance. Use StreamWriter fo

(self, input, errors='strict')

Source from the content-addressed store, hash-verified

136
137 """
138 def encode(self, input, errors='strict'):
139
140 """ Encodes the object input and returns a tuple (output
141 object, length consumed).
142
143 errors defines the error handling to apply. It defaults to
144 'strict' handling.
145
146 The method may not store state in the Codec instance. Use
147 StreamWriter for codecs which have to keep state in order to
148 make encoding efficient.
149
150 The encoder must be able to handle zero length input and
151 return an empty object of the output object type in this
152 situation.
153
154 """
155 raise NotImplementedError
156
157 def decode(self, input, errors='strict'):
158

Callers 15

handleMethod · 0.45
demoserver.pyFile · 0.45
_write_file_prefixFunction · 0.45
create_archiveFunction · 0.45
get_source_segmentFunction · 0.45
escape_charMethod · 0.45
encodeFunction · 0.45
fsencodeFunction · 0.45
_raw_inputFunction · 0.45
_putcmdMethod · 0.45
formatyearpageMethod · 0.45
mainFunction · 0.45

Calls

no outgoing calls

Tested by 2

outMethod · 0.36
_toAsciiMethod · 0.36