pub struct IrRequest {
pub method: MethodName,
pub id: Option<RequestId>,
pub params: IrParams,
pub extensions: Extensions,
}Expand description
A request. Expects exactly one result or error.
Fields§
§method: MethodNameThe method being called.
id: Option<RequestId>The request id, None only for a request the peer malformed.
params: IrParamsThe parameters.
extensions: ExtensionsUnmodelled fields on the envelope itself.
Implementations§
Source§impl IrRequest
impl IrRequest
Sourcepub const fn new(method: MethodName, id: RequestId) -> Self
pub const fn new(method: MethodName, id: RequestId) -> Self
A request with no parameters.
Sourcepub fn with_params(self, params: IrParams) -> Self
pub fn with_params(self, params: IrParams) -> Self
Attaches parameters.
Trait Implementations§
impl StructuralPartialEq for IrRequest
Auto Trait Implementations§
impl Freeze for IrRequest
impl RefUnwindSafe for IrRequest
impl Send for IrRequest
impl Sync for IrRequest
impl Unpin for IrRequest
impl UnsafeUnpin for IrRequest
impl UnwindSafe for IrRequest
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