pub struct ServerJsonrpcResponse {
pub id: RequestId,
pub result: ResultFromServer,
/* private fields */
}
Expand description
“Similar to JsonrpcResponse , but with the variants restricted to server-side responses.”
Fields§
§id: RequestId
§result: ResultFromServer
Implementations§
Source§impl ServerJsonrpcResponse
impl ServerJsonrpcResponse
pub fn new(id: RequestId, result: ResultFromServer) -> ServerJsonrpcResponse
pub fn jsonrpc(&self) -> &String
Trait Implementations§
Source§impl Clone for ServerJsonrpcResponse
impl Clone for ServerJsonrpcResponse
Source§fn clone(&self) -> ServerJsonrpcResponse
fn clone(&self) -> ServerJsonrpcResponse
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ServerJsonrpcResponse
impl Debug for ServerJsonrpcResponse
Source§impl<'de> Deserialize<'de> for ServerJsonrpcResponse
impl<'de> Deserialize<'de> for ServerJsonrpcResponse
Source§fn deserialize<D>(
deserializer: D,
) -> Result<ServerJsonrpcResponse, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<ServerJsonrpcResponse, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for ServerJsonrpcResponse
Formats the ServerJsonrpcResponse as a JSON string.
impl Display for ServerJsonrpcResponse
Formats the ServerJsonrpcResponse as a JSON string.
Source§impl FromStr for ServerJsonrpcResponse
impl FromStr for ServerJsonrpcResponse
Source§impl Serialize for ServerJsonrpcResponse
impl Serialize for ServerJsonrpcResponse
Source§fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for ServerJsonrpcResponse
impl RefUnwindSafe for ServerJsonrpcResponse
impl Send for ServerJsonrpcResponse
impl Sync for ServerJsonrpcResponse
impl Unpin for ServerJsonrpcResponse
impl UnwindSafe for ServerJsonrpcResponse
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string
, but without panic on OOM.