#eosio #dapp #crypto #blockchain #eos

eosio_numstr

Basic helper functions to work with EOSIO names and symbols

3 unstable releases

0.3.0 Feb 4, 2020
0.2.2 Jun 12, 2019
0.2.1 Jun 2, 2019

#3 in #eos

Download history 8/week @ 2024-01-12 3/week @ 2024-01-19 2/week @ 2024-02-02 5/week @ 2024-02-09 24/week @ 2024-02-16 29/week @ 2024-02-23 22/week @ 2024-03-01 27/week @ 2024-03-08 20/week @ 2024-03-15 25/week @ 2024-03-22 84/week @ 2024-03-29 41/week @ 2024-04-05 38/week @ 2024-04-12 41/week @ 2024-04-19 14/week @ 2024-04-26

152 downloads per month
Used in 8 crates (4 directly)

MIT/Apache

20KB
362 lines

Build Status

eosio_numstr

This crate provides functions for converting EOSIO names and symbols to and from string representations.

Creating an EOSIO name:

use eosio_numstr::name_from_bytes;
let name = name_from_bytes("eosio".bytes()).unwrap();
assert_eq!(name, 6138663577826885632);

Creating an EOSIO symbol:

use eosio_numstr::symbol_from_bytes;
let symbol = symbol_from_bytes(4, "EOS".bytes()).unwrap();
assert_eq!(symbol, 1162826500);

License: MIT OR Apache-2.0


lib.rs:

This crate provides functions for converting EOSIO names and symbols to and from string representations.

Creating an EOSIO name:

use eosio_numstr::name_from_bytes;
let name = name_from_bytes("eosio".bytes()).unwrap();
assert_eq!(name, 6138663577826885632);

Creating an EOSIO symbol:

use eosio_numstr::symbol_from_bytes;
let symbol = symbol_from_bytes(4, "EOS".bytes()).unwrap();
assert_eq!(symbol, 1162826500);

No runtime deps