use-pg-schema 0.1.0

PostgreSQL schema and search-path primitives for RustUse
Documentation
  • Coverage
  • 96.77%
    30 out of 31 items documented1 out of 21 items with examples
  • Size
  • Source code size: 11.98 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 641.29 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 5s Average build duration of successful builds.
  • all releases: 5s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • RustUse/use-postgres
    1 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • CloudBranch

use-pg-schema

PostgreSQL schema and search-path primitives for RustUse.

This crate provides schema names, common schema constants, schema classification helpers, and vector-backed search-path metadata. It does not inspect a live database.

Example

use use_pg_schema::{PgSchemaClass, PgSchemaName, PgSearchPath, classify_schema};

let mut path = PgSearchPath::public();
let app = PgSchemaName::new("app")?;
path.push(app.clone());

assert_eq!(path.to_string(), "public, app");
assert!(path.contains(&app));
assert_eq!(classify_schema("pg_catalog"), PgSchemaClass::SystemCatalog);
assert!(PgSchemaName::pg_catalog().is_system());
# Ok::<(), use_pg_schema::PgSchemaError>(())