8000 GitHub - aviate-labs/encoding.mo: Encoding Package for Motoko
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

aviate-labs/encoding.mo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Encoding

Docs

Base32

Implements base32 encoding as specified by RFC 4648.

Base64

Implements base64 encoding as specified by RFC 4648.

Binary

Provides simple translation between numbers and byte sequences.

Usage

Binary.LittleEndian.fromNat16(0xFF)
// [255, 0]

Binary.BigEndian.fromNat16(0xFF)
// [0, 255]

Hex

Provides hexadecimal encoding and decoding methods for Motoko.

Usage

Encode an array of unsigned 8-bit integers in hexadecimal format.

encode(ns : [Nat8]) : Text

Decode an array of unsigned 8-bit integers in hexadecimal format.

decode(t : Text) : Result<[Nat8],Text>

About

Encoding Package for Motoko

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published
0