ave_common/lib.rs
1//! # Ave Common
2//!
3//! Common types and utilities for Ave without heavy dependencies.
4//!
5//! This crate re-exports essential types needed for working with Ave,
6//! such as identity and cryptography, without pulling in heavy dependencies
7//! like wasmtime that don't compile on all architectures.
8//!
9//! ## Usage
10//!
11//! ```rust
12//! use ave_common::{
13//! identity::{KeyPair, Signature, KeyPairAlgorithm},
14//! ValueWrapper,
15//! };
16//!
17//! // Create a new keypair
18//! let keypair = KeyPair::generate(KeyPairAlgorithm::Ed25519).unwrap();
19//!
20//! // Sign some data
21//! let data = b"Hello, Ave!";
22//! let signature = Signature::new(data, &keypair).unwrap();
23//!
24//! // Verify signature
25//! assert!(signature.verify(data).is_ok());
26//!
27//! // Use ValueWrapper
28//! let value = ValueWrapper::default();
29//! ```
30
31// Re-export the entire identity module
32pub use ave_identity as identity;
33pub use borsh;
34
35pub mod wrapper;
36// Internal modules
37pub mod error;
38pub mod namespace;
39pub mod bridge;
40pub mod request;
41pub mod schematype;
42
43// Re-export commonly used types
44pub use error::Error;
45pub use schematype::SchemaType;
46pub use namespace::Namespace;
47pub use bridge::*;
48pub use wrapper::ValueWrapper;