Skip to main content

hydracache_core/
lib.rs

1//! Core types for HydraCache.
2//!
3//! This crate intentionally contains no database adapter and no distributed runtime.
4//! It defines the small set of types shared by the v0 local cache.
5
6mod codec;
7mod error;
8mod events;
9mod key;
10mod options;
11mod stats;
12mod tags;
13
14pub use codec::{CacheCodec, PostcardCodec};
15pub use error::CacheError;
16pub use events::{
17    CacheEvent, CacheEventKind, CacheEventOptions, CacheEventOrigin, CacheEventScope,
18    CacheEventValueMode,
19};
20pub use key::{CacheKey, CacheKeyBuilder};
21pub use options::CacheOptions;
22pub use stats::{CacheDiagnostics, CacheStats};
23pub use tags::TagSet;
24
25/// HydraCache result type.
26pub type Result<T> = std::result::Result<T, CacheError>;