lance_namespace/lib.rs
1// SPDX-License-Identifier: Apache-2.0
2// SPDX-FileCopyrightText: Copyright The Lance Authors
3
4//! Lance Namespace Rust Client
5//!
6//! A Rust client for the Lance Namespace API that provides a unified interface
7//! for managing namespaces and tables across different backend implementations.
8//!
9//! # Error Handling
10//!
11//! This crate provides fine-grained error types through the [`error`] module.
12//! Each error type has a unique numeric code that is consistent across all
13//! Lance Namespace implementations (Python, Java, Rust, REST).
14//!
15//! See [`error::ErrorCode`] for the list of error codes and
16//! [`error::NamespaceError`] for the error types.
17
18pub mod error;
19pub mod namespace;
20pub mod schema;
21
22// Re-export the trait at the crate root
23pub use lance_core::{Error, Result};
24pub use namespace::LanceNamespace;
25
26// Re-export error types
27pub use error::{ErrorCode, NamespaceError, Result as NamespaceResult};
28
29// Re-export reqwest client for convenience
30pub use lance_namespace_reqwest_client as reqwest_client;
31
32// Re-export commonly used models from the reqwest client
33pub mod models {
34 pub use lance_namespace_reqwest_client::models::*;
35}
36
37// Re-export APIs from the reqwest client
38pub mod apis {
39 pub use lance_namespace_reqwest_client::apis::*;
40}