pub struct QueryBuilder { /* private fields */ }
Expand description
Builder for a query request.
Implementations§
Source§impl QueryBuilder
impl QueryBuilder
Sourcepub fn start(self, time: SystemTime) -> Self
pub fn start(self, time: SystemTime) -> Self
Set the start time of the query.
Sourcepub fn start_us(self, time_us: u64) -> Self
pub fn start_us(self, time_us: u64) -> Self
Set the start time of the query as a unix timestamp in microseconds.
Sourcepub fn stop(self, time: SystemTime) -> Self
pub fn stop(self, time: SystemTime) -> Self
Set the end time of the query.
Sourcepub fn stop_us(self, time_us: u64) -> Self
pub fn stop_us(self, time_us: u64) -> Self
Set the end time of the query as a unix timestamp in microseconds.
Sourcepub fn strict(self, strict: bool) -> Self
pub fn strict(self, strict: bool) -> Self
Set the query to be strict. If the query is strict, the query will return an error if any of the conditions are invalid. default: false
Sourcepub fn ext(self, ext: Value) -> Self
pub fn ext(self, ext: Value) -> Self
Set extension parameters for the query. This is a JSON object that will be passed to extensions on the server side.
Sourcepub fn each_s(self, each_s: f64) -> Self
👎Deprecated since 1.15.0: Use $each_t
operator in when
condition. It will be removed in v1.18.0.
pub fn each_s(self, each_s: f64) -> Self
$each_t
operator in when
condition. It will be removed in v1.18.0.Set S, to return a record every S seconds. default: return all records
Sourcepub fn each_n(self, each_n: u64) -> Self
👎Deprecated since 1.15.0: Use $each_n
operator in when
condition. It will be removed in v1.18.0.
pub fn each_n(self, each_n: u64) -> Self
$each_n
operator in when
condition. It will be removed in v1.18.0.Set N, to return every N records. default: return all records
Sourcepub fn limit(self, limit: u64) -> Self
👎Deprecated since 1.15.0: Use $limit
operator in when
condition. It will be removed in v1.18.0.
pub fn limit(self, limit: u64) -> Self
$limit
operator in when
condition. It will be removed in v1.18.0.Set a limit for the query. default: unlimited
Sourcepub fn continuous(self) -> Self
pub fn continuous(self) -> Self
Set the query to be continuous.
Sourcepub async fn send(
self,
) -> Result<impl Stream<Item = Result<Record, ReductError>>, ReductError>
pub async fn send( self, ) -> Result<impl Stream<Item = Result<Record, ReductError>>, ReductError>
Send the query request.
Auto Trait Implementations§
impl Freeze for QueryBuilder
impl !RefUnwindSafe for QueryBuilder
impl Send for QueryBuilder
impl Sync for QueryBuilder
impl Unpin for QueryBuilder
impl !UnwindSafe for QueryBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more