Table of Contents

Class RemoteMethodNotFoundException

Namespace
StreamJsonRpc
Assembly
StreamJsonRpc.dll

Remote RPC exception that indicates that the requested target method was not found on the server.

[Serializable]
public class RemoteMethodNotFoundException : RemoteRpcException, ISerializable
Inheritance
RemoteMethodNotFoundException
Implements
Inherited Members

Remarks

Check the exception message for the reasons why the method was not found. It's possible that there was a method with the matching name, but it was not public, had ref or out params, or its arguments were incompatible with the arguments supplied by the client.

Constructors

RemoteMethodNotFoundException(SerializationInfo, StreamingContext)

Initializes a new instance of the RemoteMethodNotFoundException class.

protected RemoteMethodNotFoundException(SerializationInfo info, StreamingContext context)

Parameters

info SerializationInfo

Serialization info.

context StreamingContext

Streaming context.

Properties

DeserializedErrorData

Gets or sets the error.data value in the error response, if one was provided.

public object? DeserializedErrorData { get; }

Property Value

object

Remarks

The type of this object is determined by GetErrorDetailsDataType(JsonRpcError). The default implementation of this method produces a CommonErrorData object.

ErrorCode

Gets the value of the error.code field in the response.

public JsonRpcErrorCode ErrorCode { get; }

Property Value

JsonRpcErrorCode

The value is typically either InvalidParams or MethodNotFound.

ErrorData

Gets or sets the error.data value in the error response, if one was provided.

public object? ErrorData { get; }

Property Value

object

Remarks

Depending on the IJsonRpcMessageFormatter used, the value of this property, if any, may be a Newtonsoft.Json.Linq.JToken or a deserialized object. If a deserialized object, the type of this object is determined by GetErrorDetailsDataType(JsonRpcError). The default implementation of this method produces a CommonErrorData object.

TargetMethod

Gets the name of the target method that was not found.

public string TargetMethod { get; }

Property Value

string

Methods

GetObjectData(SerializationInfo, StreamingContext)

public override void GetObjectData(SerializationInfo info, StreamingContext context)

Parameters

info SerializationInfo
context StreamingContext