Skip to content

Commit

Permalink
clean README for clarity
Browse files Browse the repository at this point in the history
Signed-off-by: Dave Huseby <dwh@linuxprogrammer.org>
  • Loading branch information
dhuseby committed Apr 7, 2024
1 parent 325657d commit 80fb509
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,17 @@

# Multihash

Multiformats multihash implementation without size in the type signature. Uses
the [`multiutil::BaseEncoded`] smart pointers to wrap the Multihash into
EncodecMultihash for base encoded multihashes. This automates the
encoding/decoding to/from strings and byte slices for multihashes. It also has
serde support to/from human readable and binary formats. It also supports raw
binary encoding and decoding using [`Into<Vec<u8>>`] and [`TryFrom<&[u8]>`]
trait implementations.
Multiformats [Multihash][MULTIHASH] implementation without constant size in the
type signature.

## Features

* Uses the [`multiutil::BaseEncoded`] smart pointers to wrap the Multihash into
EncodecMultihash for base encoded multihashes; automating the
encoding/decoding to/from strings and byte slices.
* Serde support to/from human readable and binary formats.
* Supports raw binary encoding and decoding using [`Into<Vec<u8>>`] and
[`TryFrom<&[u8]>`] trait implementations.

## Examples

Expand Down Expand Up @@ -47,3 +51,4 @@ let encoded_mh2: EncodedMultihash::new(Base::Base32Upper, mh);
[CRYPTID]: https://cryptid.tech/
[PROVENANCE]: https://github.com/cryptidtech/provenance-specifications/
[MULTIFORMATS]: https://github.com/multiformats/multiformats/
[MULTIHASH]: https://www.multiformats.io/multihash/

0 comments on commit 80fb509

Please sign in to comment.