pub struct PostResponse {
pub post: PostRequest,
pub response: Vec<u8>,
pub timeout_timestamp: u64,
}
Expand description
The response to a POST request
Fields§
§post: PostRequest
The request that triggered this response.
response: Vec<u8>
The response message.
timeout_timestamp: u64
Timestamp at which this response expires in seconds.
Implementations§
Source§impl PostResponse
impl PostResponse
Sourcepub fn source_module(&self) -> Vec<u8> ⓘ
pub fn source_module(&self) -> Vec<u8> ⓘ
Module where this response originated on source chain
Sourcepub fn destination_module(&self) -> Vec<u8> ⓘ
pub fn destination_module(&self) -> Vec<u8> ⓘ
Module that this response will be routed to on destination chain
Sourcepub fn source_chain(&self) -> StateMachine
pub fn source_chain(&self) -> StateMachine
Get the source chain for this response
Sourcepub fn dest_chain(&self) -> StateMachine
pub fn dest_chain(&self) -> StateMachine
Get the destination chain for this response
Trait Implementations§
Source§impl Clone for PostResponse
impl Clone for PostResponse
Source§fn clone(&self) -> PostResponse
fn clone(&self) -> PostResponse
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for PostResponse
impl Debug for PostResponse
Source§impl Decode for PostResponse
impl Decode for PostResponse
Source§fn decode<__CodecInputEdqy: Input>(
__codec_input_edqy: &mut __CodecInputEdqy,
) -> Result<Self, Error>
fn decode<__CodecInputEdqy: Input>( __codec_input_edqy: &mut __CodecInputEdqy, ) -> Result<Self, Error>
Attempt to deserialise the value from input.
Source§fn decode_into<I>(
input: &mut I,
dst: &mut MaybeUninit<Self>,
) -> Result<DecodeFinished, Error>where
I: Input,
fn decode_into<I>(
input: &mut I,
dst: &mut MaybeUninit<Self>,
) -> Result<DecodeFinished, Error>where
I: Input,
Attempt to deserialize the value from input into a pre-allocated piece of memory. Read more
Source§impl<'de> Deserialize<'de> for PostResponse
impl<'de> Deserialize<'de> for PostResponse
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Encode for PostResponse
impl Encode for PostResponse
Source§fn size_hint(&self) -> usize
fn size_hint(&self) -> usize
If possible give a hint of expected size of the encoding. Read more
Source§fn encode_to<__CodecOutputEdqy: Output + ?Sized>(
&self,
__codec_dest_edqy: &mut __CodecOutputEdqy,
)
fn encode_to<__CodecOutputEdqy: Output + ?Sized>( &self, __codec_dest_edqy: &mut __CodecOutputEdqy, )
Convert self to a slice and append it to the destination.
Source§fn using_encoded<R, F>(&self, f: F) -> R
fn using_encoded<R, F>(&self, f: F) -> R
Convert self to a slice and then invoke the given closure with it.
Source§fn encoded_size(&self) -> usize
fn encoded_size(&self) -> usize
Calculates the encoded size. Read more
Source§impl From<&PostResponse> for Meta
impl From<&PostResponse> for Meta
Source§fn from(value: &PostResponse) -> Self
fn from(value: &PostResponse) -> Self
Converts to this type from the input type.
Source§impl From<PostResponse> for Response
impl From<PostResponse> for Response
Source§fn from(value: PostResponse) -> Self
fn from(value: PostResponse) -> Self
Converts to this type from the input type.
Source§impl From<PostResponse> for Timeout
impl From<PostResponse> for Timeout
Source§fn from(value: PostResponse) -> Self
fn from(value: PostResponse) -> Self
Converts to this type from the input type.
Source§impl PartialEq for PostResponse
impl PartialEq for PostResponse
Source§impl Serialize for PostResponse
impl Serialize for PostResponse
Source§impl TypeInfo for PostResponse
impl TypeInfo for PostResponse
impl DecodeWithMemTracking for PostResponse
impl EncodeLike for PostResponse
impl Eq for PostResponse
impl StructuralPartialEq for PostResponse
Auto Trait Implementations§
impl Freeze for PostResponse
impl RefUnwindSafe for PostResponse
impl Send for PostResponse
impl Sync for PostResponse
impl Unpin for PostResponse
impl UnwindSafe for PostResponse
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DecodeLimit for Twhere
T: Decode,
impl<T> DecodeLimit for Twhere
T: Decode,
Source§impl<T> DecodeWithMemLimit for Twhere
T: DecodeWithMemTracking,
impl<T> DecodeWithMemLimit for Twhere
T: DecodeWithMemTracking,
Source§impl<T> SaturatedConversion for T
impl<T> SaturatedConversion for T
Source§fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
Source§fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
Consume self to return an equivalent value of
T
. Read moreSource§impl<T, S> UniqueSaturatedInto<T> for S
impl<T, S> UniqueSaturatedInto<T> for S
Source§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
Consume self to return an equivalent value of
T
.