47 releases (5 breaking)

Uses old Rust 2015

0.6.1 Jul 7, 2017
0.5.7 Jul 5, 2017

#1 in #wdg

Download history 36/week @ 2024-07-26 2/week @ 2024-08-02 49/week @ 2024-09-20 26/week @ 2024-09-27 1/week @ 2024-10-04

97 downloads per month

MIT license

140KB
2K SLoC

rust-base32

Build Status Build status Docs.rs Crates.io License

Install

Cargo.toml

[dependencies]
wdg-base32="*"

How to use?

    B32::<type>::encode(data);
    B32::<type>::validation(data);
    B32::<type>::decode(data);
    B32::<type>::unsafe_decode(data);
type u8/i8 u16/i16 u32/i32 u64/i64 String
encode -/- -/- -/- -/- +
validation +/+ +/+ +/+ +/+ +
decode +/+ +/+ +/+ +/+ +

Examples

extern crate wdg_base32;
use wdg_base32::{B32,B32Encode,B32Decode};

fn main(){

    // u8
    println!("{}",B32::<String>::encode(5u8));

    // u16
    println!("{}",B32::<String>::encode(5u16));

}

Dependencies