[−][src]Struct grpc::StreamingResponse
Streaming response
Methods
impl<T: Send + 'static> StreamingResponse<T>
[src]
pub fn new<F>(f: F) -> StreamingResponse<T> where
F: Future<Item = (Metadata, GrpcStreamWithTrailingMetadata<T>), Error = Error> + Send + 'static,
[src]
F: Future<Item = (Metadata, GrpcStreamWithTrailingMetadata<T>), Error = Error> + Send + 'static,
pub fn metadata_and_stream_and_trailing_metadata<S, M>(
metadata: Metadata,
result: S,
trailing: M
) -> StreamingResponse<T> where
S: Stream<Item = T, Error = Error> + Send + 'static,
M: Future<Item = Metadata, Error = Error> + Send + 'static,
[src]
metadata: Metadata,
result: S,
trailing: M
) -> StreamingResponse<T> where
S: Stream<Item = T, Error = Error> + Send + 'static,
M: Future<Item = Metadata, Error = Error> + Send + 'static,
pub fn metadata_and_stream<S>(
metadata: Metadata,
result: S
) -> StreamingResponse<T> where
S: Stream<Item = T, Error = Error> + Send + 'static,
[src]
metadata: Metadata,
result: S
) -> StreamingResponse<T> where
S: Stream<Item = T, Error = Error> + Send + 'static,
pub fn no_metadata<S>(s: S) -> StreamingResponse<T> where
S: Stream<Item = T, Error = Error> + Send + 'static,
[src]
S: Stream<Item = T, Error = Error> + Send + 'static,
pub fn completed_with_metadata_and_trailing_metadata(
metadata: Metadata,
r: Vec<T>,
trailing: Metadata
) -> StreamingResponse<T>
[src]
metadata: Metadata,
r: Vec<T>,
trailing: Metadata
) -> StreamingResponse<T>
pub fn completed_with_metadata(
metadata: Metadata,
r: Vec<T>
) -> StreamingResponse<T>
[src]
metadata: Metadata,
r: Vec<T>
) -> StreamingResponse<T>
pub fn iter_with_metadata_and_trailing_metadata<I, M>(
metadata: Metadata,
iter: I,
trailing: M
) -> StreamingResponse<T> where
I: Iterator<Item = T> + Send + 'static,
M: Future<Item = Metadata, Error = Error> + Send + 'static,
[src]
metadata: Metadata,
iter: I,
trailing: M
) -> StreamingResponse<T> where
I: Iterator<Item = T> + Send + 'static,
M: Future<Item = Metadata, Error = Error> + Send + 'static,
pub fn iter_with_metadata<I>(
metadata: Metadata,
iter: I
) -> StreamingResponse<T> where
I: Iterator<Item = T> + Send + 'static,
[src]
metadata: Metadata,
iter: I
) -> StreamingResponse<T> where
I: Iterator<Item = T> + Send + 'static,
pub fn completed(r: Vec<T>) -> StreamingResponse<T>
[src]
pub fn iter<I>(iter: I) -> StreamingResponse<T> where
I: Iterator<Item = T> + Send + 'static,
[src]
I: Iterator<Item = T> + Send + 'static,
pub fn empty() -> StreamingResponse<T>
[src]
pub fn err(err: Error) -> StreamingResponse<T>
[src]
Create an error response
pub fn map_items<U, F>(self, f: F) -> StreamingResponse<U> where
U: Send + 'static,
F: FnMut(T) -> U + Send + 'static,
[src]
U: Send + 'static,
F: FnMut(T) -> U + Send + 'static,
pub fn and_then_items<U, F>(self, f: F) -> StreamingResponse<U> where
U: Send + 'static,
F: FnMut(T) -> Result<U> + Send + 'static,
[src]
U: Send + 'static,
F: FnMut(T) -> Result<U> + Send + 'static,
pub fn drop_metadata(self) -> GrpcStream<T>
[src]
pub fn into_future(self) -> SingleResponse<Vec<T>>
[src]
pub fn single(self) -> SingleResponse<T>
[src]
Take single element from stream
pub fn wait(
self
) -> Result<(Metadata, Box<dyn Iterator<Item = Result<T>> + Send>)>
[src]
self
) -> Result<(Metadata, Box<dyn Iterator<Item = Result<T>> + Send>)>
pub fn wait_drop_metadata(self) -> Box<dyn Iterator<Item = Result<T>> + Send>
[src]
pub fn collect(self) -> GrpcFuture<(Metadata, Vec<T>, Metadata)>
[src]
Auto Trait Implementations
impl<T> !RefUnwindSafe for StreamingResponse<T>
impl<T> Send for StreamingResponse<T>
impl<T> !Sync for StreamingResponse<T>
impl<T> Unpin for StreamingResponse<T>
impl<T> !UnwindSafe for StreamingResponse<T>
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, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
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>,