correlationvector_rust/
lib.rs

1//! A rust library for working with Correlation Vectors.
2//! The library provides a struct for CorrelationVector and methods for working with them.
3//! Learn more about the methods in the [Readme](https://github.com/TransientError/CorrelationVector-rust/blob/master/cvlib/Readme.md)
4//! or in the [specification](https://github.com/microsoft/CorrelationVector).
5//! ```rust
6//! use cvlib::CorrelationVector;
7//!
8//! let mut cv = CorrelationVector::new(); // e.g. wC71fJEqSPuHrPQ9ZoXrKg.0
9//! cv.extend(); // e.g. wC71fJEqSPuHrPQ9ZoXrKg.0.0
10//! cv.increment(); // e.g. wC71fJEqSPuHrPQ9ZoXrKg.0.1
11//! let cv_string = cv.to_string(); // create string representation of CV
12//!
13//! let cv_parsed = CorrelationVector::parse(&cv_string); // parse the string representation of the correlation vector
14//! ```
15
16mod correlationvector;
17mod correlationvectorparsererror;
18mod spinparams;
19
20pub use correlationvector::CorrelationVector;
21pub use correlationvectorparsererror::CorrelationVectorParseError;
22pub use spinparams::{SpinCounterInterval, SpinCounterPeriodicity, SpinEntropy, SpinParams};