Struct tonic::body::BoxBody[][src]

pub struct BoxBody { /* fields omitted */ }

A type erased http body.

Implementations

impl BoxBody[src]

pub fn new<B>(inner: B) -> Self where
    B: Body<Data = Bytes, Error = Status> + Send + Sync + 'static, 
[src]

Create a new BoxBody mapping item and error to the default types.

pub fn map_from<B>(inner: B) -> Self where
    B: Body + Send + Sync + 'static,
    B::Error: Into<Box<dyn Error + Send + Sync>>, 
[src]

Create a new BoxBody mapping item and error to the default types.

pub fn empty() -> Self[src]

Create a new BoxBody that is empty.

Trait Implementations

impl Body for BoxBody[src]

type Data = Bytes

Values yielded by the Body.

type Error = Status

The error type this Body might generate.

impl Debug for BoxBody[src]

impl GrpcService<BoxBody> for Channel[src]

type ResponseBody = Body

Responses body given by the service.

type Error = Error

Errors produced by the service.

type Future = ResponseFuture

The future response value.

Auto Trait Implementations

impl !RefUnwindSafe for BoxBody

impl Send for BoxBody

impl Sync for BoxBody

impl Unpin for BoxBody

impl !UnwindSafe for BoxBody

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Body for T where
    T: Body + Send + Sync + 'static,
    <T as Body>::Error: Into<Box<dyn Error + 'static + Send + Sync, Global>>, 
[src]

type Data = <T as Body>::Data

The body data type.

type Error = <T as Body>::Error

The errors produced from the body.

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> Instrument for T[src]

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

impl<T> Pointable for T[src]

type Init = T

The type for initializers.

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>, 
[src]

impl<T> WithSubscriber for T[src]