Struct fluvio_protocol_api::RequestMessage [−][src]
pub struct RequestMessage<R> { pub header: RequestHeader, pub request: R, }
Expand description
Start of API request
Fields
header: RequestHeader
request: R
Implementations
impl<R> RequestMessage<R>
[src]
impl<R> RequestMessage<R>
[src]pub fn get_mut_header(&mut self) -> &mut RequestHeader
[src]
impl<R> RequestMessage<R> where
R: Request,
[src]
impl<R> RequestMessage<R> where
R: Request,
[src]pub fn new(header: RequestHeader, request: R) -> Self
[src]
pub fn new(header: RequestHeader, request: R) -> Self
[src]create with header, this assume header is constructed from higher request no api key check is performed since it is already done
pub fn new_request(request: R) -> Self
[src]
pub fn new_request(request: R) -> Self
[src]create from request, header is implicilty created from key in the request
pub fn get_header_request(self) -> (RequestHeader, R)
[src]
pub fn request(&self) -> &R
[src]
pub fn new_response(
&self,
response: R::Response
) -> ResponseMessage<R::Response>
[src]
&self,
response: R::Response
) -> ResponseMessage<R::Response>
pub fn response_with_header<H>(
header: H,
response: R::Response
) -> ResponseMessage<R::Response> where
H: Into<i32>,
[src]
header: H,
response: R::Response
) -> ResponseMessage<R::Response> where
H: Into<i32>,
pub fn decode_response<T>(
&self,
src: &mut T,
version: Version
) -> Result<ResponseMessage<R::Response>, IoError> where
T: Buf,
[src]
&self,
src: &mut T,
version: Version
) -> Result<ResponseMessage<R::Response>, IoError> where
T: Buf,
pub fn decode_response_from_file<H: AsRef<Path>>(
&self,
file_name: H,
version: Version
) -> Result<ResponseMessage<R::Response>, IoError>
[src]
&self,
file_name: H,
version: Version
) -> Result<ResponseMessage<R::Response>, IoError>
pub fn set_client_id<T>(self, client_id: T) -> Self where
T: Into<String>,
[src]
pub fn set_client_id<T>(self, client_id: T) -> Self where
T: Into<String>,
[src]helper function to set client id
Trait Implementations
impl<R: Debug> Debug for RequestMessage<R>
[src]
impl<R: Debug> Debug for RequestMessage<R>
[src]impl<R> Decoder for RequestMessage<R> where
R: Request,
[src]
impl<R> Decoder for RequestMessage<R> where
R: Request,
[src]impl<R> Default for RequestMessage<R> where
R: Request + Default,
[src]
impl<R> Default for RequestMessage<R> where
R: Request + Default,
[src]impl<R> Display for RequestMessage<R> where
R: Display,
[src]
impl<R> Display for RequestMessage<R> where
R: Display,
[src]impl<R> Encoder for RequestMessage<R> where
R: Request,
[src]
impl<R> Encoder for RequestMessage<R> where
R: Request,
[src]Auto Trait Implementations
impl<R> RefUnwindSafe for RequestMessage<R> where
R: RefUnwindSafe,
R: RefUnwindSafe,
impl<R> Send for RequestMessage<R> where
R: Send,
R: Send,
impl<R> Sync for RequestMessage<R> where
R: Sync,
R: Sync,
impl<R> Unpin for RequestMessage<R> where
R: Unpin,
R: Unpin,
impl<R> UnwindSafe for RequestMessage<R> where
R: UnwindSafe,
R: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]