Skip to main content

Crate gantz_ca

Crate gantz_ca 

Source
Expand description

The content-addressing abstractions for gantz.

Modules§

registry
A registry tracking graphs, commits and names (branches).

Structs§

Commit
A commit captures a snapshot of a Graph.
CommitAddr
The content address of a commit.
ContentAddr
The content address of a graph.
ContentAddrShort
Provides a Display implementation that formats the CA into shorthand form.
GraphAddr
The content address of a graph.
Registry
A registry of content-addressed graphs, commits of those graphs, and optional names for those commits.

Enums§

Head
Acts as a pointer to the current working graph, whether directly to a commit or to a name mapping.

Traits§

CaHash
Types that can be hashed to produce a content address.

Functions§

commit_addr
Shorthand for producing the address of a Commit.
content_addr
Hash some type implementing CaHash.
graph_addr
Calculate the content address of a graph.
graph_addr_with_nodes
A more efficient alternative to addr for when the node content addresses are already known.
hash_graph
The implementation of addr with hasher provided.
hash_graph_with_nodes
The implementation of addr_with_nodes with hasher provided.
node_addrs
Hash all the nodes and return a map from node IDs to their content addresses.

Type Aliases§

Branch
Represents a name used to track a working series of commits.
Hasher
The blake3 hasher used for gantz’ content addressing.
Timestamp
The timestamp of a commit, represented as the duration since UNIX_EPOCH.

Derive Macros§

CaHash
Re-export the derive macro. Derive macro for CaHash.