use-node 0.0.1

Primitive node identifiers and node helpers
Documentation
  • Coverage
  • 14.29%
    1 out of 7 items documented1 out of 7 items with examples
  • Size
  • Source code size: 4.19 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 340.32 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 33s Average build duration of successful builds.
  • all releases: 33s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • RustUse/use-graph
    1 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • CloudBranch

Primitive node identifier helpers.

The crate keeps node identifiers explicit and lightweight through a small NodeId wrapper around usize.

Examples

use use_node::{NodeId, contains_node, node_ids, unique_nodes};

let nodes = node_ids(3);
let unique = unique_nodes(&[NodeId::new(2), NodeId::new(1), NodeId::new(2)]);

assert!(contains_node(&nodes, NodeId::new(1)));
assert_eq!(unique, vec![NodeId::new(2), NodeId::new(1)]);