pub const fn from_code(code: i64) -> Self {
        match code {
            -32700 => ErrorCode::ParseError,
            -32600 => ErrorCode::InvalidRequest,
            -32601 => ErrorCode::MethodNotFound,
            -32602 => ErrorCode::InvalidParams,
            -32603 => ErrorCode::InternalError,
            code => ErrorCode::ServerError(code),
        }
    }
///Creates new instance from code.
Creates new instance from code.
Creates new instance from code .
pub const fn from_code(code: i64) -> Self {
        match code {
            -32700 => ErrorCode::ParseError,
            -32600 => ErrorCode::InvalidRequest,
            -32601 => ErrorCode::MethodNotFound,
            -32602 => ErrorCode::InvalidParams,
            -32603 => ErrorCode::InternalError,
            code => ErrorCode::ServerError(code),
        }
    }
pub const fn from_code ( code : i64 ) -> Self { match code { - 32700 => ErrorCode :: ParseError , - 32600 => ErrorCode :: InvalidRequest , - 32601 => ErrorCode :: MethodNotFound , - 32602 => ErrorCode :: InvalidParams , - 32603 => ErrorCode :: InternalError , code => ErrorCode :: ServerError ( code ) , } }
Creates new instance from code.
Creates new instance from code .
code
i64
code
i64