[][src]Struct grpc::ServerRequest

pub struct ServerRequest<'a, M: 'static> { /* fields omitted */ }

Streaming server request.

This object is passed to server handlers.

Methods

impl<'a, M: Send + 'static> ServerRequest<'a, M>[src]

pub fn metadata(&self) -> Metadata[src]

Get request metadata.

pub fn register_stream_handler<F, H, R>(self, handler: F) -> R where
    H: ServerRequestStreamHandler<M>,
    F: FnOnce(ServerIncreaseInWindow) -> (H, R)
[src]

Register server stream handler.

This is low level operation, hard to use. Most users use into_stream operation.

pub fn register_stream_handler_basic<H>(self, handler: H) where
    H: FnMut(Option<M>) -> Result<()> + Send + 'static, 
[src]

Register basic stream handler (without manual control flow).

This is low level operation, hard to use. Most users use into_stream operation.

pub fn register_unary_handler<H>(self, handler: H) where
    H: ServerRequestUnaryHandler<M>, 
[src]

Register unary request handler.

Few people need this operation.

pub fn into_stream(self) -> ServerRequestStream<M>[src]

Convert request into easy to use ServerRequestStream object.

Auto Trait Implementations

impl<'a, M> !RefUnwindSafe for ServerRequest<'a, M>

impl<'a, M> Send for ServerRequest<'a, M>

impl<'a, M> !Sync for ServerRequest<'a, M>

impl<'a, M> Unpin for ServerRequest<'a, M>

impl<'a, M> !UnwindSafe for ServerRequest<'a, M>

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, U> Into<U> for T where
    U: From<T>, 
[src]

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.