pub struct ProgressNotification {
pub params: ProgressNotificationParams,
/* private fields */
}Expand description
An out-of-band notification used to inform the receiver of a progress update for a long-running request.
JSON schema
{
"description": "An out-of-band notification used to inform the receiver of a progress update for a long-running request.",
"type": "object",
"required": [
"jsonrpc",
"method",
"params"
],
"properties": {
"jsonrpc": {
"type": "string",
"const": "2.0"
},
"method": {
"type": "string",
"const": "notifications/progress"
},
"params": {
"$ref": "#/$defs/ProgressNotificationParams"
}
}
}Fields§
§params: ProgressNotificationParamsImplementations§
Source§impl ProgressNotification
impl ProgressNotification
pub fn new(params: ProgressNotificationParams) -> Self
pub fn jsonrpc(&self) -> &String
pub fn method(&self) -> &String
Sourcepub fn method_value() -> &'static str
pub fn method_value() -> &'static str
returns “notifications/progress”
pub fn method_name() -> &'static str
👎Deprecated since 0.8.0: Use
method_value() instead.Trait Implementations§
Source§impl Clone for ProgressNotification
impl Clone for ProgressNotification
Source§fn clone(&self) -> ProgressNotification
fn clone(&self) -> ProgressNotification
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 ProgressNotification
impl Debug for ProgressNotification
Source§impl<'de> Deserialize<'de> for ProgressNotification
impl<'de> Deserialize<'de> for ProgressNotification
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 From<ProgressNotification> for ClientNotification
impl From<ProgressNotification> for ClientNotification
Source§fn from(value: ProgressNotification) -> Self
fn from(value: ProgressNotification) -> Self
Converts to this type from the input type.
Source§impl From<ProgressNotification> for ServerNotification
impl From<ProgressNotification> for ServerNotification
Source§fn from(value: ProgressNotification) -> Self
fn from(value: ProgressNotification) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ProgressNotification
impl RefUnwindSafe for ProgressNotification
impl Send for ProgressNotification
impl Sync for ProgressNotification
impl Unpin for ProgressNotification
impl UnwindSafe for ProgressNotification
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