JsonRpc.Attach Metoda
Ważne
Niektóre informacje odnoszą się do produktu w wersji wstępnej, który może zostać znacząco zmodyfikowany przed wydaniem. Firma Microsoft nie udziela żadnych gwarancji, jawnych lub domniemanych, w odniesieniu do informacji podanych w tym miejscu.
Attach(Type) |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Attach(Stream, Object) |
Inicjuje JsonRpc nowe wystąpienie klasy, które używa HeaderDelimitedMessageHandler wokół komunikatów serializowanych przy użyciu klasy JsonMessageFormatter, i natychmiast rozpoczyna nasłuchiwanie. |
Attach(Type, JsonRpcProxyOptions) |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Attach(Stream, Stream, Object) |
Inicjuje JsonRpc nowe wystąpienie klasy, które używa HeaderDelimitedMessageHandler wokół komunikatów serializowanych przy użyciu klasy JsonMessageFormatter, i natychmiast rozpoczyna nasłuchiwanie. |
Attach<T>(Stream, Stream) |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Attach<T>(IJsonRpcMessageHandler, JsonRpcProxyOptions) |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Attach<T>(Stream) |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Attach<T>(IJsonRpcMessageHandler) |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Attach<T>() |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Attach<T>(JsonRpcProxyOptions) |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera. |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public object Attach (Type interfaceType);
member this.Attach : Type -> obj
Public Function Attach (interfaceType As Type) As Object
Parametry
- interfaceType
- Type
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Inicjuje JsonRpc nowe wystąpienie klasy, które używa HeaderDelimitedMessageHandler wokół komunikatów serializowanych przy użyciu klasy JsonMessageFormatter, i natychmiast rozpoczyna nasłuchiwanie.
public static StreamJsonRpc.JsonRpc Attach (System.IO.Stream stream, object target = default);
public static StreamJsonRpc.JsonRpc Attach (System.IO.Stream stream, object? target = default);
static member Attach : System.IO.Stream * obj -> StreamJsonRpc.JsonRpc
Public Shared Function Attach (stream As Stream, Optional target As Object = Nothing) As JsonRpc
Parametry
- stream
- Stream
Strumień dwukierunkowy do wysyłania i odbierania komunikatów RPC.
- target
- Object
Opcjonalny obiekt docelowy, który ma być wywoływany po odebraniu przychodzących żądań RPC.
Zwraca
Zainicjowany i nasłuchiwanie JsonRpc obiektu.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 1.3, 1.5, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public object Attach (Type interfaceType, StreamJsonRpc.JsonRpcProxyOptions options);
public object Attach (Type interfaceType, StreamJsonRpc.JsonRpcProxyOptions? options);
member this.Attach : Type * StreamJsonRpc.JsonRpcProxyOptions -> obj
Public Function Attach (interfaceType As Type, options As JsonRpcProxyOptions) As Object
Parametry
- interfaceType
- Type
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
- options
- JsonRpcProxyOptions
Zestaw dostosowań dotyczących przewodowego serwera proxy klienta. Jeśli null
zostanie użyta opcja domyślna.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Inicjuje JsonRpc nowe wystąpienie klasy, które używa HeaderDelimitedMessageHandler wokół komunikatów serializowanych przy użyciu klasy JsonMessageFormatter, i natychmiast rozpoczyna nasłuchiwanie.
public static StreamJsonRpc.JsonRpc Attach (System.IO.Stream sendingStream, System.IO.Stream receivingStream, object target = default);
public static StreamJsonRpc.JsonRpc Attach (System.IO.Stream? sendingStream, System.IO.Stream? receivingStream, object? target = default);
static member Attach : System.IO.Stream * System.IO.Stream * obj -> StreamJsonRpc.JsonRpc
Public Shared Function Attach (sendingStream As Stream, receivingStream As Stream, Optional target As Object = Nothing) As JsonRpc
Parametry
- sendingStream
- Stream
Strumień używany do przesyłania komunikatów. Może mieć wartość null.
- receivingStream
- Stream
Strumień używany do odbierania komunikatów. Może mieć wartość null.
- target
- Object
Opcjonalny obiekt docelowy, który ma być wywoływany po odebraniu przychodzących żądań RPC.
Zwraca
Zainicjowany i nasłuchiwanie JsonRpc obiektu.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 1.3, 1.5, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public static T Attach<T> (System.IO.Stream sendingStream, System.IO.Stream receivingStream) where T : class;
public static T Attach<T> (System.IO.Stream? sendingStream, System.IO.Stream? receivingStream) where T : class;
static member Attach : System.IO.Stream * System.IO.Stream -> 'T (requires 'T : null)
Public Shared Function Attach(Of T As Class) (sendingStream As Stream, receivingStream As Stream) As T
Parametry typu
- T
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
Parametry
- sendingStream
- Stream
Strumień używany do przesyłania komunikatów. Może mieć wartość null.
- receivingStream
- Stream
Strumień używany do odbierania komunikatów. Może mieć wartość null.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Oprócz implementacji T
, implementuje IDisposable również element i powinien zostać usunięty, aby zamknąć połączenie.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 1.5, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public static T Attach<T> (StreamJsonRpc.IJsonRpcMessageHandler handler, StreamJsonRpc.JsonRpcProxyOptions options) where T : class;
public static T Attach<T> (StreamJsonRpc.IJsonRpcMessageHandler handler, StreamJsonRpc.JsonRpcProxyOptions? options) where T : class;
static member Attach : StreamJsonRpc.IJsonRpcMessageHandler * StreamJsonRpc.JsonRpcProxyOptions -> 'T (requires 'T : null)
Public Shared Function Attach(Of T As Class) (handler As IJsonRpcMessageHandler, options As JsonRpcProxyOptions) As T
Parametry typu
- T
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
Parametry
- handler
- IJsonRpcMessageHandler
Procedura obsługi komunikatów do użycia.
- options
- JsonRpcProxyOptions
Zestaw dostosowań dotyczących przewodowego serwera proxy klienta. Jeśli null
zostanie użyta opcja domyślna.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Oprócz implementacji T
, implementuje IDisposable również element i powinien zostać usunięty, aby zamknąć połączenie.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public static T Attach<T> (System.IO.Stream stream) where T : class;
static member Attach : System.IO.Stream -> 'T (requires 'T : null)
Public Shared Function Attach(Of T As Class) (stream As Stream) As T
Parametry typu
- T
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
Parametry
- stream
- Stream
Strumień dwukierunkowy używany do wysyłania i odbierania komunikatów JSON-RPC.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Oprócz implementacji T
, implementuje IDisposable również element i powinien zostać usunięty, aby zamknąć połączenie.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 1.5, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public static T Attach<T> (StreamJsonRpc.IJsonRpcMessageHandler handler) where T : class;
static member Attach : StreamJsonRpc.IJsonRpcMessageHandler -> 'T (requires 'T : null)
Public Shared Function Attach(Of T As Class) (handler As IJsonRpcMessageHandler) As T
Parametry typu
- T
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
Parametry
- handler
- IJsonRpcMessageHandler
Procedura obsługi komunikatów do użycia.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Oprócz implementacji T
, implementuje IDisposable również element i powinien zostać usunięty, aby zamknąć połączenie.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public T Attach<T> () where T : class;
member this.Attach : unit -> 'T (requires 'T : null)
Public Function Attach(Of T As Class) () As T
Parametry typu
- T
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 1.5, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |
Tworzy serwer proxy klienta JSON-RPC zgodny z określonym interfejsem serwera.
public T Attach<T> (StreamJsonRpc.JsonRpcProxyOptions options) where T : class;
public T Attach<T> (StreamJsonRpc.JsonRpcProxyOptions? options) where T : class;
member this.Attach : StreamJsonRpc.JsonRpcProxyOptions -> 'T (requires 'T : null)
Public Function Attach(Of T As Class) (options As JsonRpcProxyOptions) As T
Parametry typu
- T
Interfejs, który opisuje funkcje dostępne na końcu zdalnym.
Parametry
- options
- JsonRpcProxyOptions
Zestaw dostosowań dotyczących przewodowego serwera proxy klienta. Jeśli null
zostanie użyta opcja domyślna.
Zwraca
Wystąpienie wygenerowanego serwera proxy.
Dotyczy
StreamJsonRpc 2.9 i inne wersje
Produkt | Wersje |
---|---|
StreamJsonRpc | 1.5, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9 |