rust-postgres/postgres/src/lib.rs

48 lines
1.1 KiB
Rust
Raw Normal View History

2019-03-31 03:58:01 +00:00
//!
#![warn(clippy::all, rust_2018_idioms, missing_docs)]
2019-03-24 20:32:29 +00:00
2018-12-21 21:34:09 +00:00
#[cfg(feature = "runtime")]
use lazy_static::lazy_static;
#[cfg(feature = "runtime")]
use tokio::runtime::{self, Runtime};
2019-03-26 04:03:22 +00:00
pub use tokio_postgres::{error, row, tls, types, Column, Portal, SimpleQueryMessage, Statement};
pub use crate::client::*;
#[cfg(feature = "runtime")]
pub use crate::config::Config;
pub use crate::copy_out_reader::*;
#[doc(no_inline)]
pub use crate::error::Error;
pub use crate::query_iter::*;
pub use crate::query_portal_iter::*;
#[doc(no_inline)]
pub use crate::row::{Row, SimpleQueryRow};
pub use crate::simple_query_iter::*;
#[doc(no_inline)]
pub use crate::tls::NoTls;
pub use crate::to_statement::*;
pub use crate::transaction::*;
2018-12-30 05:06:24 +00:00
mod client;
2018-12-21 21:34:09 +00:00
#[cfg(feature = "runtime")]
2019-03-26 04:03:22 +00:00
pub mod config;
2018-12-29 05:01:10 +00:00
mod copy_out_reader;
mod query_iter;
mod query_portal_iter;
mod simple_query_iter;
2018-12-29 04:20:31 +00:00
mod to_statement;
2018-12-21 21:46:50 +00:00
mod transaction;
2018-12-21 21:34:09 +00:00
2018-12-22 05:01:49 +00:00
#[cfg(feature = "runtime")]
#[cfg(test)]
mod test;
2018-12-21 21:34:09 +00:00
#[cfg(feature = "runtime")]
lazy_static! {
static ref RUNTIME: Runtime = runtime::Builder::new()
.name_prefix("postgres-")
.build()
.unwrap();
}