[][src]Struct noria::prelude::View

pub struct View { /* fields omitted */ }

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]

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]

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]

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.

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]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Sealed<T> for T where
    T: ?Sized

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

impl<T> WithSubscriber for T[src]