(result: R, id: T)
| 122 | |
| 123 | impl<R> JsonRpcResponse<R> { |
| 124 | pub fn success<T: Into<String>>(result: R, id: T) -> Self { |
| 125 | Self { |
| 126 | id: id.into(), |
| 127 | body: JsonRpcResponseBody::Success { result }, |
| 128 | } |
| 129 | } |
| 130 | |
| 131 | pub fn into_result(self) -> std::result::Result<R, RpcError> { |
| 132 | self.body.into_result() |
no outgoing calls
no test coverage detected