Skip to main content

mongreldb_kit_core/
lib.rs

1//! Core, language-neutral model for MongrelDB Kit.
2//!
3//! This crate contains the schema model, key encoding, validation, constraint
4//! planning, migration planning, and query AST used by the storage-backed
5//! `mongreldb-kit` crate and by language bindings.
6
7pub mod check;
8pub mod keys;
9pub mod migrations;
10pub mod planner;
11pub mod query;
12pub mod schema;
13pub mod validation;
14
15pub use check::{eval_check, CheckParseError};
16pub use keys::{
17    decode_pk, encode_component, encode_pk, encode_row_guard_key, encode_unique_key, KeyComponent,
18    KIT_KEY_VERSION,
19};
20pub use migrations::{migration_checksum, plan_migrations, Migration, MigrationOp};
21pub use planner::{
22    plan_delete, DeletePlan, PlannerError, RestrictedConstraint, RowRef, SetNullUpdate,
23};
24pub use query::{
25    AggFunc, Aggregate, AggregateQuery, Cte, Delete, Direction, Expr, Insert, Join, JoinKind,
26    JoinQuery, Literal, OnConflict, OrderBy, Query, Select, Update, Upsert,
27};
28pub use schema::{
29    CheckConstraint, Column, ColumnType, DefaultKind, ForeignKey, ForeignKeyAction, Index,
30    IndexKind, Schema, SchemaError, Sequence, Table, UniqueConstraint,
31};
32pub use validation::{validate_row, ValidationError};