Skip to main content

odbc_api/
lib.rs

1//! # About
2//!
3//! `odbc-api` enables you to write applications which utilize ODBC (Open Database Connectivity)
4//! standard to access databases. See the [`guide`] for more information and code
5//! examples.
6
7mod catalog;
8mod columnar_bulk_inserter;
9mod connection;
10mod conversion;
11mod cursor;
12mod driver_complete_option;
13mod environment;
14mod error;
15mod execute;
16mod fixed_sized;
17mod into_parameter;
18mod narrow;
19mod nullable;
20mod parameter_collection;
21mod preallocated;
22mod preallocated_polling;
23mod prepared;
24mod result_set_metadata;
25mod shared_connection;
26mod sleep;
27
28pub mod buffers;
29pub mod guide;
30pub mod handles;
31pub mod parameter;
32
33pub use self::{
34    catalog::{ColumnsRow, ForeignKeysRow, PrimaryKeysRow, TablesRow},
35    columnar_bulk_inserter::{
36        BoundInputSlice, ColumnarBulkInserter, InOrder, InputParameterMapping,
37    },
38    connection::{Connection, ConnectionOptions, ConnectionTransitions, escape_attribute_value},
39    conversion::{decimal_text_to_i32, decimal_text_to_i64, decimal_text_to_i128},
40    cursor::{
41        BlockCursor, BlockCursorIterator, BlockCursorPolling, ConcurrentBlockCursor, Cursor,
42        CursorImpl, CursorPolling, CursorRow, RowSetBuffer, TruncationInfo,
43    },
44    driver_complete_option::DriverCompleteOption,
45    environment::{DataSourceInfo, DriverInfo, Environment, environment},
46    error::{Error, TooLargeBufferSize},
47    fixed_sized::Bit,
48    handles::{ColumnDescription, DataType, Nullability},
49    into_parameter::IntoParameter,
50    narrow::Narrow,
51    nullable::Nullable,
52    parameter::{InOut, Out, OutputParameter},
53    parameter_collection::{ParameterCollection, ParameterCollectionRef, ParameterTupleElement},
54    preallocated::Preallocated,
55    preallocated_polling::PreallocatedPolling,
56    prepared::{BindParamDesc, Prepared},
57    result_set_metadata::ResultSetMetadata,
58    shared_connection::SharedConnection,
59    sleep::Sleep,
60};
61
62/// Reexports `odbc-sys` as sys to enable applications to always use the same version as this
63/// crate.
64pub use odbc_sys as sys;
65pub use widestring::{U16Str, U16String};
66
67// Reexport fetch if derive feature is enabled
68#[cfg(feature = "derive")]
69pub use odbc_api_derive::Fetch;