encoding Module
Note:
The encoding module cannot be imported through import encoding. Otherwise, the error message "error: can not find package'encoding'" is displayed during compilation. You are advised to import the encoding subpackage to use the encoding module.
encoding Function Description
The encoding module provides character encoding and decoding capabilities.
It can encode and decode data in Base64, Hex, JSON, and URL formats.
Package List of the encoding Module
The encoding module provides the following packages:
Name | Description |
---|---|
base64 | The base package provides Base64 encoding and decoding for strings. |
hex | The hex package provides Hex encoding and decoding for strings. |
json | The json package is used to process json data and implement conversion among String, JsonValue, and DataModel. |
json.stream | The json.stream package is used for conversion between Cangjie objects and JSON data streams. |
url | The url package provides URL-related capabilities, including parsing URL components, encoding and decoding URLs, and combining URLs or paths. |