Treatment decode
encoding::decode
Parameters
↳ var encoding:
string = "utf-8"
Inputs
⇥ data:
Stream<byte>
Outputs
↦ text:
Stream<string>
Decodes stream of bytes into string.
The incoming stream of bytes is decoded using the specified encoding.
If some characters cannot be decoded for some reason (i.e. invalid according to encoding),
it is replaced by the U+FFFD REPLACEMENT CHARACTER
(�).
The supported encodings and possible values for encoding
are defined in
the Encoding Standard.
If encoding
is not recognized, UTF-8 is assumed instead.