rusticx_core/lib.rs
1//! Core traits and types for Rusticx ORM.
2//!
3//! This crate provides the foundational abstractions that all Rusticx backends
4//! build on. End users work with the top-level `rusticx` crate, not this one
5//! directly — but understanding these types helps when implementing custom
6//! backends or advanced use cases.
7//!
8//! # Key types
9//!
10//! | Type | Purpose |
11//! |---|---|
12//! | [`model::Model`] | Trait every struct must implement (via `#[derive(Model)]`) |
13//! | [`repository::Repository`] | Typed CRUD repository for one model |
14//! | [`adapter::DatabaseAdapter`] | Async trait all backends implement |
15//! | [`adapter::SyncAdapter`] | Blocking wrapper for non-async contexts |
16//! | [`query::QueryBuilder`] | Composable, backend-agnostic query builder |
17//! | [`value::Value`] | Universal value enum bridging Rust ↔ database |
18//! | [`error::RusticxError`] | All errors this crate can produce |
19
20pub mod adapter;
21pub mod column;
22pub mod error;
23pub mod macros_support;
24pub mod model;
25pub mod query;
26pub mod repository;
27pub mod value;
28
29pub use error::{Result, RusticxError};