Table of Contents

Class ServiceJsonRpcDescriptor<T>

Namespace
Microsoft.ServiceHub.Framework
Assembly
Microsoft.ServiceHub.Framework.dll

An RPC descriptor for services that support JSON-RPC.

public class ServiceJsonRpcDescriptor<T> : ServiceJsonRpcDescriptor, IEquatable<ServiceJsonRpcDescriptor> where T : class

Type Parameters

T

The RPC interface used to call the service.

Inheritance
ServiceJsonRpcDescriptor<T>
Implements
Inherited Members

Constructors

ServiceJsonRpcDescriptor(ServiceJsonRpcDescriptor<T>)

Initializes a new instance of the ServiceJsonRpcDescriptor<T> class and initializes all fields based on a template instance.

protected ServiceJsonRpcDescriptor(ServiceJsonRpcDescriptor<T> copyFrom)

Parameters

copyFrom ServiceJsonRpcDescriptor<T>

The instance to copy all fields from.

ServiceJsonRpcDescriptor(ServiceMoniker, Formatters, MessageDelimiters)

Initializes a new instance of the ServiceJsonRpcDescriptor<T> class.

public ServiceJsonRpcDescriptor(ServiceMoniker serviceMoniker, ServiceJsonRpcDescriptor.Formatters formatter, ServiceJsonRpcDescriptor.MessageDelimiters messageDelimiter)

Parameters

serviceMoniker ServiceMoniker

The service moniker.

formatter ServiceJsonRpcDescriptor.Formatters

The formatter to use for the JSON-RPC message.

messageDelimiter ServiceJsonRpcDescriptor.MessageDelimiters

The message delimiter scheme to use.

ServiceJsonRpcDescriptor(ServiceMoniker, Type?, Formatters, MessageDelimiters)

Initializes a new instance of the ServiceJsonRpcDescriptor<T> class.

public ServiceJsonRpcDescriptor(ServiceMoniker serviceMoniker, Type? clientInterface, ServiceJsonRpcDescriptor.Formatters formatter, ServiceJsonRpcDescriptor.MessageDelimiters messageDelimiter)

Parameters

serviceMoniker ServiceMoniker

The service moniker.

clientInterface Type

The interface type that the client's "callback" RPC target is expected to implement. May be null if the service does not invoke methods on the client.

formatter ServiceJsonRpcDescriptor.Formatters

The formatter to use for the JSON-RPC message.

messageDelimiter ServiceJsonRpcDescriptor.MessageDelimiters

The message delimiter scheme to use.

Methods

Clone()

Creates a copy of this instance with all the same properties.

protected override ServiceRpcDescriptor Clone()

Returns

ServiceRpcDescriptor

The copy.

Remarks

Derived types should override this method to create a new instance of their own type, using the ServiceRpcDescriptor(ServiceRpcDescriptor) copy constructor, then copy all their unique properties from this instance to the new one before returning the new one.