(&self)
| 40 | } |
| 41 | |
| 42 | pub fn method(&self) -> Option<&str> { |
| 43 | match self { |
| 44 | Message::Request(Request { method, .. }) => Some(method), |
| 45 | Message::Notification(Notification { method, .. }) => Some(method), |
| 46 | _ => None, |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | pub fn id(&self) -> Option<Id> { |
| 51 | match self { |