1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
// Copyright Claudio Mattera 2021.
// Distributed under the MIT License or Apache 2.0 License at your option.
// See accompanying files License-MIT.txt and License-Apache-2.0, or online at
// https://opensource.org/licenses/MIT
// https://opensource.org/licenses/Apache-2.0

#![doc = include_str!("../Readme.md")]

pub use rinfluxdb_types as types;

#[cfg(feature = "lineprotocol")]
pub use rinfluxdb_lineprotocol as line_protocol;

#[cfg(feature = "influxql")]
pub use rinfluxdb_influxql as influxql;

#[cfg(feature = "flux")]
pub use rinfluxdb_flux as flux;

#[cfg(feature = "dataframe")]
pub use rinfluxdb_dataframe as dataframe;

#[cfg(feature = "polars")]
pub use rinfluxdb_polars as polars;

#[cfg(all(feature = "client", feature = "flux"))]
/// A client for performing frequent Flux queries in a convenient way
pub type FluxClient = flux::blocking::Client;

#[cfg(all(feature = "client", feature = "flux"))]
/// A client for performing frequent asynchronous Flux queries in a convenient way
pub type FluxAsyncClient = flux::r#async::Client;

/// A Flux query
#[cfg(feature = "flux")]
pub type FluxQuery = flux::Query;

/// A builder for Flux queries
#[cfg(feature = "flux")]
pub type FluxQueryBuilder = flux::QueryBuilder;

#[cfg(all(feature = "client", feature = "influxql"))]
/// A client for performing frequent InfluxQL queries in a convenient way
pub type InfluxqlClient = influxql::blocking::Client;

#[cfg(all(feature = "client", feature = "influxql"))]
/// A client for performing frequent asynchronous InfluxQL queries in a convenient way
pub type InfluxqlAsyncClient = influxql::r#async::Client;

/// An InfluxQL query
#[cfg(feature = "influxql")]
pub type InfluxqlQuery = influxql::Query;

/// A builder for InfluxQL queries
#[cfg(feature = "influxql")]
pub type InfluxqlQueryBuilder = influxql::QueryBuilder;

#[cfg(all(feature = "client", feature = "lineprotocol"))]
/// A client for sending data with Influx Line Protocol queries in a convenient
/// way
pub type InfluxLineClient = line_protocol::blocking::Client;

#[cfg(all(feature = "client", feature = "lineprotocol"))]
/// A client for asynchronously sending data with Influx Line Protocol queries in a convenient
/// way
pub type InfluxAsyncLineClient = line_protocol::r#async::Client;

/// A line in the Influx Line Protocol
#[cfg(feature = "lineprotocol")]
pub type InfluxLine = line_protocol::Line;

/// A builder for Influx Line Protocol lines
#[cfg(feature = "lineprotocol")]
pub type InfluxLineBuilder = line_protocol::LineBuilder;