[−][src]Struct noria::prelude::View
A View
is used to query previously defined external views.
Note that if you create multiple View
handles from a single ControllerHandle
, they may
share connections to the Soup workers.
Implementations
impl View
[src]
pub fn columns(&self) -> &[String]
[src]
Get the list of columns in this view.
pub fn schema(&self) -> Option<&[ColumnSpecification]>
[src]
Get the schema definition of this view.
pub async fn len<'_>(&'_ mut self) -> Result<usize, ViewError>
[src]
Get the current size of this view.
Note that you must also continue to poll this View
for the returned future to resolve.
pub async fn multi_lookup<'_>(
&'_ mut self,
keys: Vec<Vec<DataType>>,
block: bool
) -> Result<Vec<Results>, ViewError>
[src]
&'_ mut self,
keys: Vec<Vec<DataType>>,
block: bool
) -> Result<Vec<Results>, ViewError>
Retrieve the query results for the given parameter values.
The method will block if the results are not yet available only when block
is true
.
If block
is false, misses will be returned as empty results. Any requested keys that have
missing state will be backfilled (asynchronously if block
is false
).
pub async fn lookup<'_, '_>(
&'_ mut self,
key: &'_ [DataType],
block: bool
) -> Result<Results, ViewError>
[src]
&'_ mut self,
key: &'_ [DataType],
block: bool
) -> Result<Results, ViewError>
Retrieve the query results for the given parameter value.
The method will block if the results are not yet available only when block
is true
.
pub async fn lookup_first<'_, '_>(
&'_ mut self,
key: &'_ [DataType],
block: bool
) -> Result<Option<Row>, ViewError>
[src]
&'_ mut self,
key: &'_ [DataType],
block: bool
) -> Result<Option<Row>, ViewError>
Retrieve the first query result for the given parameter value.
The method will block if the results are not yet available only when block
is true
.
Trait Implementations
impl Clone for View
[src]
impl Debug for View
[src]
impl Service<(Vec<Vec<DataType>>, bool)> for View
[src]
type Response = Vec<Results>
Responses given by the service.
type Error = ViewError
Errors produced by the service.
type Future = Future<Result<Self::Response, Self::Error>>
The future response value.
fn poll_ready(&mut self, cx: &mut Context) -> Poll<Result<(), Self::Error>>
[src]
fn call(&mut self, (keys, block): (Vec<Vec<DataType>>, bool)) -> Self::Future
[src]
Auto Trait Implementations
impl !RefUnwindSafe for View
impl Send for View
impl Sync for View
impl Unpin for View
impl !UnwindSafe for View
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> Sealed<T> for T where
T: ?Sized,
T: ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,
fn vzip(self) -> V
impl<T> WithSubscriber for T
[src]
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
[src]
S: Into<Dispatch>,