-
Notifications
You must be signed in to change notification settings - Fork 1.5k
/
TcpChannel.xml
584 lines (505 loc) · 40.1 KB
/
TcpChannel.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
<Type Name="TcpChannel" FullName="System.Runtime.Remoting.Channels.Tcp.TcpChannel">
<TypeSignature Language="C#" Value="public class TcpChannel : System.Runtime.Remoting.Channels.IChannelReceiver, System.Runtime.Remoting.Channels.IChannelSender" FrameworkAlternate="netframework-1.1" />
<TypeSignature Language="ILAsm" Value=".class public auto ansi beforefieldinit TcpChannel extends System.Object implements class System.Runtime.Remoting.Channels.IChannel, class System.Runtime.Remoting.Channels.IChannelReceiver, class System.Runtime.Remoting.Channels.IChannelSender" FrameworkAlternate="netframework-1.1" />
<TypeSignature Language="DocId" Value="T:System.Runtime.Remoting.Channels.Tcp.TcpChannel" />
<TypeSignature Language="VB.NET" Value="Public Class TcpChannel
Implements IChannelReceiver, IChannelSender" FrameworkAlternate="netframework-1.1" />
<TypeSignature Language="F#" Value="type TcpChannel = class
 interface IChannelReceiver
 interface IChannelSender
 interface IChannel" FrameworkAlternate="netframework-1.1" />
<TypeSignature Language="C++ CLI" Value="public ref class TcpChannel : System::Runtime::Remoting::Channels::IChannelReceiver, System::Runtime::Remoting::Channels::IChannelSender" FrameworkAlternate="netframework-1.1" />
<TypeSignature Language="C#" Value="public class TcpChannel : System.Runtime.Remoting.Channels.IChannelReceiver, System.Runtime.Remoting.Channels.IChannelSender, System.Runtime.Remoting.Channels.ISecurableChannel" FrameworkAlternate="netframework-2.0;netframework-3.0;netframework-3.5;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1" />
<TypeSignature Language="ILAsm" Value=".class public auto ansi beforefieldinit TcpChannel extends System.Object implements class System.Runtime.Remoting.Channels.IChannel, class System.Runtime.Remoting.Channels.IChannelReceiver, class System.Runtime.Remoting.Channels.IChannelSender, class System.Runtime.Remoting.Channels.ISecurableChannel" FrameworkAlternate="netframework-2.0;netframework-3.0;netframework-3.5;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1" />
<TypeSignature Language="VB.NET" Value="Public Class TcpChannel
Implements IChannelReceiver, IChannelSender, ISecurableChannel" FrameworkAlternate="netframework-2.0;netframework-3.0;netframework-3.5;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1" />
<TypeSignature Language="F#" Value="type TcpChannel = class
 interface IChannelReceiver
 interface IChannelSender
 interface IChannel
 interface ISecurableChannel" FrameworkAlternate="netframework-2.0;netframework-3.0;netframework-3.5;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2" />
<TypeSignature Language="C++ CLI" Value="public ref class TcpChannel : System::Runtime::Remoting::Channels::IChannelReceiver, System::Runtime::Remoting::Channels::IChannelSender, System::Runtime::Remoting::Channels::ISecurableChannel" FrameworkAlternate="netframework-2.0;netframework-3.0;netframework-3.5;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1" />
<TypeSignature Language="F#" Value="type TcpChannel = class
 interface IChannelReceiver
 interface IChannel
 interface IChannelSender
 interface ISecurableChannel" FrameworkAlternate="netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1" />
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Base>
<BaseTypeName>System.Object</BaseTypeName>
</Base>
<Interfaces>
<Interface>
<InterfaceName>System.Runtime.Remoting.Channels.IChannel</InterfaceName>
</Interface>
<Interface>
<InterfaceName>System.Runtime.Remoting.Channels.IChannelReceiver</InterfaceName>
</Interface>
<Interface>
<InterfaceName>System.Runtime.Remoting.Channels.IChannelSender</InterfaceName>
</Interface>
<Interface FrameworkAlternate="netframework-2.0;netframework-3.0;netframework-3.5;netframework-4.0;netframework-4.5;netframework-4.5.1;netframework-4.5.2;netframework-4.6;netframework-4.6.1;netframework-4.6.2;netframework-4.7;netframework-4.7.1;netframework-4.7.2;netframework-4.8;netframework-4.8.1">
<InterfaceName>System.Runtime.Remoting.Channels.ISecurableChannel</InterfaceName>
</Interface>
</Interfaces>
<Docs>
<summary>Provides a channel implementation that uses the TCP protocol to transmit messages.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
[!INCLUDE [untrusted-data-class-note](~/includes/untrusted-data-class-note.md)]
Channels transport messages across remoting boundaries (for example, between computers on application domains). The <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel> class is a convenience class combining the functionality of the <xref:System.Runtime.Remoting.Channels.Tcp.TcpClientChannel> class and the <xref:System.Runtime.Remoting.Channels.Tcp.TcpServerChannel> class.
Channels are used by the .NET Framework remoting infrastructure to transport remote calls. When a client makes a call to a remote object, the call is serialized into a message that is sent by a client channel and received by a server channel. It is then deserialized and processed. Any returned values are transmitted by the server channel and received by the client channel.
To perform additional processing of messages, you can specify implementations of the <xref:System.Runtime.Remoting.Channels.IClientChannelSinkProvider> and <xref:System.Runtime.Remoting.Channels.IServerChannelSinkProvider> through which all messages processed by the <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel> are passed.
A <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel> object has associated configuration properties that can be set at run time either in a configuration file (by invoking the static <xref:System.Runtime.Remoting.RemotingConfiguration.Configure%2A?displayProperty=nameWithType> method) or programmatically (by passing a <xref:System.Collections.IDictionary> collection to the <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel.%23ctor%2A> constructor). For more information about channel configuration properties, see [Channel and Formatter Configuration Properties](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/kw7c6kwc(v=vs.100)).
## Examples
The following code example shows how to use a <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel> to set up a remoting server and its client. The example contains three parts, a server, a client, and a remote object used by the server and the client.
The following code example shows a server:
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/server.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/server.cs" id="Snippet1":::
The following code example shows a client for this server:
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/client.cpp" id="Snippet10":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/client.cs" id="Snippet10":::
The following code example shows the remote object used by the server and the client:
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/common.cpp" id="Snippet20":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/common.cs" id="Snippet20":::
]]></format>
</remarks>
</Docs>
<Members>
<MemberGroup MemberName=".ctor">
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Docs>
<summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Channels.Tcp.TcpChannel" /> class.</summary>
</Docs>
</MemberGroup>
<Member MemberName=".ctor">
<MemberSignature Language="C#" Value="public TcpChannel ();" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor() cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.#ctor" />
<MemberSignature Language="VB.NET" Value="Public Sub New ()" />
<MemberSignature Language="C++ CLI" Value="public:
 TcpChannel();" />
<MemberType>Constructor</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Parameters />
<Docs>
<summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Channels.Tcp.TcpChannel" /> class, activating only a client channel, and not a server channel.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
The parameterless constructor initializes all fields to their default values. If the parameterless constructor is used, the channel functions only as a client channel, and does not listen on any ports.
## Examples
The following code example shows how to use this constructor.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/client.cpp" id="Snippet11":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/client.cs" id="Snippet11":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName=".ctor">
<MemberSignature Language="C#" Value="public TcpChannel (int port);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(int32 port) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.#ctor(System.Int32)" />
<MemberSignature Language="VB.NET" Value="Public Sub New (port As Integer)" />
<MemberSignature Language="F#" Value="new System.Runtime.Remoting.Channels.Tcp.TcpChannel : int -> System.Runtime.Remoting.Channels.Tcp.TcpChannel" Usage="new System.Runtime.Remoting.Channels.Tcp.TcpChannel port" />
<MemberSignature Language="C++ CLI" Value="public:
 TcpChannel(int port);" />
<MemberType>Constructor</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Parameters>
<Parameter Name="port" Type="System.Int32" />
</Parameters>
<Docs>
<param name="port">The port on which the server channel listens.</param>
<summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Channels.Tcp.TcpChannel" /> class with a server channel that listens on the specified port.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
To request that the remoting system choose an open port on your behalf, specify port 0 (zero). This will create a <xref:System.Runtime.Remoting.Channels.Tcp.TcpServerChannel> instance to listen for requests on the dynamically assigned port. This is typically done on the client to make sure that a <xref:System.Runtime.Remoting.Channels.Tcp.TcpServerChannel> is listening for callback methods.
If 0 is passed to the constructor the <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel> is instantiated to use a free port.
## Examples
The following code example demonstrates using this method. To request that an available port be dynamically assigned, set the `port` parameter to zero.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/RemotingConfiguration.ServerActivation/CPP/server.cpp" id="Snippet2":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/.ctor/server.cs" id="Snippet2":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/RemotingConfiguration.ServerActivation/VB/server.vb" id="Snippet2":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName=".ctor">
<MemberSignature Language="C#" Value="public TcpChannel (System.Collections.IDictionary properties, System.Runtime.Remoting.Channels.IClientChannelSinkProvider clientSinkProvider, System.Runtime.Remoting.Channels.IServerChannelSinkProvider serverSinkProvider);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(class System.Collections.IDictionary properties, class System.Runtime.Remoting.Channels.IClientChannelSinkProvider clientSinkProvider, class System.Runtime.Remoting.Channels.IServerChannelSinkProvider serverSinkProvider) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.#ctor(System.Collections.IDictionary,System.Runtime.Remoting.Channels.IClientChannelSinkProvider,System.Runtime.Remoting.Channels.IServerChannelSinkProvider)" />
<MemberSignature Language="VB.NET" Value="Public Sub New (properties As IDictionary, clientSinkProvider As IClientChannelSinkProvider, serverSinkProvider As IServerChannelSinkProvider)" />
<MemberSignature Language="F#" Value="new System.Runtime.Remoting.Channels.Tcp.TcpChannel : System.Collections.IDictionary * System.Runtime.Remoting.Channels.IClientChannelSinkProvider * System.Runtime.Remoting.Channels.IServerChannelSinkProvider -> System.Runtime.Remoting.Channels.Tcp.TcpChannel" Usage="new System.Runtime.Remoting.Channels.Tcp.TcpChannel (properties, clientSinkProvider, serverSinkProvider)" />
<MemberSignature Language="C++ CLI" Value="public:
 TcpChannel(System::Collections::IDictionary ^ properties, System::Runtime::Remoting::Channels::IClientChannelSinkProvider ^ clientSinkProvider, System::Runtime::Remoting::Channels::IServerChannelSinkProvider ^ serverSinkProvider);" />
<MemberType>Constructor</MemberType>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Parameters>
<Parameter Name="properties" Type="System.Collections.IDictionary" />
<Parameter Name="clientSinkProvider" Type="System.Runtime.Remoting.Channels.IClientChannelSinkProvider" />
<Parameter Name="serverSinkProvider" Type="System.Runtime.Remoting.Channels.IServerChannelSinkProvider" />
</Parameters>
<Docs>
<param name="properties">A <see cref="T:System.Collections.IDictionary" /> collection that specifies values for configuration properties to be used by the client and server channels.</param>
<param name="clientSinkProvider">The <see cref="T:System.Runtime.Remoting.Channels.IClientChannelSinkProvider" /> implementation to be used by the client channel.</param>
<param name="serverSinkProvider">The <see cref="T:System.Runtime.Remoting.Channels.IServerChannelSinkProvider" /> implementation to be used by the server channel.</param>
<summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Channels.Tcp.TcpChannel" /> class with the specified configuration properties and sinks.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
For more information about channel configuration properties, see [Channel and Formatter Configuration Properties](https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/kw7c6kwc(v=vs.100)).
Channel sinks provide a plug-in point that allows access to the underlying messages flowing through the channel as well as the stream used by the transport mechanism to send messages to a remote object. Channel sinks are also responsible for transporting messages between the client and the server. Channel sinks are linked together in a chain, and all channel messages flow through this chain of sinks before the message is finally serialized and transported. If you do not require sink functionality, set the `clientSinkProvider` and `serverSinkProvider` parameters to `null`.
## Examples
The following code example shows how to use this constructor.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel2/CPP/server.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/.ctor/server1.cs" id="Snippet1":::
]]></format>
</remarks>
<exception cref="T:System.ArgumentException">A provided channel property was improperly formatted.</exception>
<related type="Article" href="https://learn.microsoft.com/previous-versions/dotnet/netframework-4.0/kw7c6kwc(v=vs.100)">Channel and Formatter Configuration Properties</related>
</Docs>
</Member>
<Member MemberName="ChannelData">
<MemberSignature Language="C#" Value="public object ChannelData { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance object ChannelData" />
<MemberSignature Language="DocId" Value="P:System.Runtime.Remoting.Channels.Tcp.TcpChannel.ChannelData" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property ChannelData As Object" />
<MemberSignature Language="F#" Value="member this.ChannelData : obj" Usage="System.Runtime.Remoting.Channels.Tcp.TcpChannel.ChannelData" />
<MemberSignature Language="C++ CLI" Value="public:
 property System::Object ^ ChannelData { System::Object ^ get(); };" />
<MemberType>Property</MemberType>
<Implements>
<InterfaceMember>P:System.Runtime.Remoting.Channels.IChannelReceiver.ChannelData</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Object</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the channel-specific data.</summary>
<value>A <see cref="T:System.Runtime.Remoting.Channels.ChannelDataStore" /> instance that contains channel-specific data.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
Although returned as an instance of <xref:System.Object?displayProperty=nameWithType>, the value of this property can be cast to an instance of <xref:System.Runtime.Remoting.Channels.ChannelDataStore> describing the channel to which the <xref:System.Runtime.Remoting.Channels.Http.HttpServerChannel> object listens.
## Examples
The following code example shows how to use this property.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/server.cpp" id="Snippet5":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/server.cs" id="Snippet5":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="ChannelName">
<MemberSignature Language="C#" Value="public string ChannelName { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance string ChannelName" />
<MemberSignature Language="DocId" Value="P:System.Runtime.Remoting.Channels.Tcp.TcpChannel.ChannelName" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property ChannelName As String" />
<MemberSignature Language="F#" Value="member this.ChannelName : string" Usage="System.Runtime.Remoting.Channels.Tcp.TcpChannel.ChannelName" />
<MemberSignature Language="C++ CLI" Value="public:
 property System::String ^ ChannelName { System::String ^ get(); };" />
<MemberType>Property</MemberType>
<Implements>
<InterfaceMember>P:System.Runtime.Remoting.Channels.IChannel.ChannelName</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.String</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the name of the current channel.</summary>
<value>A <see cref="T:System.String" /> that contains the name of the channel.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
Every registered channel has a unique name. The name is used to retrieve a specific channel when calling <xref:System.Runtime.Remoting.Channels.ChannelServices.GetChannel%2A>. To set the <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel.ChannelName%2A> property, assign the value to the "name" indexed property in the dictionary passed to the <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel.%23ctor%28System.Collections.IDictionary%2CSystem.Runtime.Remoting.Channels.IClientChannelSinkProvider%2CSystem.Runtime.Remoting.Channels.IServerChannelSinkProvider%29> constructor.
## Examples
The following code example shows how to use this property.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/server.cpp" id="Snippet3":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/server.cs" id="Snippet3":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="ChannelPriority">
<MemberSignature Language="C#" Value="public int ChannelPriority { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance int32 ChannelPriority" />
<MemberSignature Language="DocId" Value="P:System.Runtime.Remoting.Channels.Tcp.TcpChannel.ChannelPriority" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property ChannelPriority As Integer" />
<MemberSignature Language="F#" Value="member this.ChannelPriority : int" Usage="System.Runtime.Remoting.Channels.Tcp.TcpChannel.ChannelPriority" />
<MemberSignature Language="C++ CLI" Value="public:
 property int ChannelPriority { int get(); };" />
<MemberType>Property</MemberType>
<Implements>
<InterfaceMember>P:System.Runtime.Remoting.Channels.IChannel.ChannelPriority</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Int32</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the priority of the current channel.</summary>
<value>An integer that represents the priority assigned to the channel.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Examples
The following code example shows how to use this property.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/server.cpp" id="Snippet4":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/server.cs" id="Snippet4":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="CreateMessageSink">
<MemberSignature Language="C#" Value="public System.Runtime.Remoting.Messaging.IMessageSink CreateMessageSink (string url, object remoteChannelData, out string objectURI);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance class System.Runtime.Remoting.Messaging.IMessageSink CreateMessageSink(string url, object remoteChannelData, [out] string& objectURI) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.CreateMessageSink(System.String,System.Object,System.String@)" />
<MemberSignature Language="VB.NET" Value="Public Function CreateMessageSink (url As String, remoteChannelData As Object, ByRef objectURI As String) As IMessageSink" />
<MemberSignature Language="F#" Value="abstract member CreateMessageSink : string * obj * string -> System.Runtime.Remoting.Messaging.IMessageSink
override this.CreateMessageSink : string * obj * string -> System.Runtime.Remoting.Messaging.IMessageSink" Usage="tcpChannel.CreateMessageSink (url, remoteChannelData, objectURI)" />
<MemberSignature Language="C++ CLI" Value="public:
 virtual System::Runtime::Remoting::Messaging::IMessageSink ^ CreateMessageSink(System::String ^ url, System::Object ^ remoteChannelData, [Runtime::InteropServices::Out] System::String ^ % objectURI);" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Runtime.Remoting.Channels.IChannelSender.CreateMessageSink(System.String,System.Object,System.String@)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Runtime.Remoting.Messaging.IMessageSink</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="url" Type="System.String" />
<Parameter Name="remoteChannelData" Type="System.Object" />
<Parameter Name="objectURI" Type="System.String" RefType="out" />
</Parameters>
<Docs>
<param name="url">The URL to which the new sink should deliver messages. Can be <see langword="null" />.</param>
<param name="remoteChannelData">The channel data object of the remote host to which the new sink should deliver messages. Can be <see langword="null" />.</param>
<param name="objectURI">When this method returns, contains a URI of the new channel message sink that delivers messages to the specified URL or channel data object. This parameter is passed uninitialized.</param>
<summary>Returns a channel message sink that delivers messages to the specified URL or channel data object.</summary>
<returns>A channel message sink that delivers messages to the specified URL or channel data object.</returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
The <xref:System.Runtime.Remoting.Channels.Tcp.TcpChannel.CreateMessageSink%2A> method returns a channel message sink that delivers messages to either the specified URL or channel data object. If the `uri` parameter is `null`, `remoteChannelData` is used as a target for the sink. Either the `url` or `remoteChannelData` parameters can be `null`, but not both.
Channel sinks provide a plug-in point that allows access to the underlying messages flowing through the channel as well as the stream used by the transport mechanism to send messages to a remote object. Channel sinks are linked together in a chain of `ChannelSinkProviders` and all channel messages flow through this chain of sinks before the message is finally serialized and transported.
## Examples
The following code example shows how to use this method.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/client.cpp" id="Snippet12":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/client.cs" id="Snippet12":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="GetUrlsForUri">
<MemberSignature Language="C#" Value="public string[] GetUrlsForUri (string objectURI);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance string[] GetUrlsForUri(string objectURI) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.GetUrlsForUri(System.String)" />
<MemberSignature Language="VB.NET" Value="Public Function GetUrlsForUri (objectURI As String) As String()" />
<MemberSignature Language="F#" Value="abstract member GetUrlsForUri : string -> string[]
override this.GetUrlsForUri : string -> string[]" Usage="tcpChannel.GetUrlsForUri objectURI" />
<MemberSignature Language="C++ CLI" Value="public:
 virtual cli::array <System::String ^> ^ GetUrlsForUri(System::String ^ objectURI);" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Runtime.Remoting.Channels.IChannelReceiver.GetUrlsForUri(System.String)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.String[]</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="objectURI" Type="System.String" />
</Parameters>
<Docs>
<param name="objectURI">The URI of the object for which URLs are required.</param>
<summary>Returns an array of all the URLs for an object with the specified URI, hosted on the current <see cref="T:System.Runtime.Remoting.Channels.Tcp.TcpChannel" />.</summary>
<returns>An array of the URLs for an object with the specified URI, hosted on the current <see cref="T:System.Runtime.Remoting.Channels.Tcp.TcpChannel" />.</returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
This method is used by <xref:System.Runtime.Remoting.Channels.ChannelServices.GetUrlsForObject%2A?displayProperty=nameWithType>.
## Examples
The following code example shows how to use this method.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/TcpChannel.GetUrlsForUri/CPP/class1.cpp" id="Snippet1":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/GetUrlsForUri/class1.cs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/TcpChannel.GetUrlsForUri/VB/class1.vb" id="Snippet1":::
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="IsSecured">
<MemberSignature Language="C#" Value="public bool IsSecured { get; set; }" />
<MemberSignature Language="ILAsm" Value=".property instance bool IsSecured" />
<MemberSignature Language="DocId" Value="P:System.Runtime.Remoting.Channels.Tcp.TcpChannel.IsSecured" />
<MemberSignature Language="VB.NET" Value="Public Property IsSecured As Boolean" />
<MemberSignature Language="F#" Value="member this.IsSecured : bool with get, set" Usage="System.Runtime.Remoting.Channels.Tcp.TcpChannel.IsSecured" />
<MemberSignature Language="C++ CLI" Value="public:
 property bool IsSecured { bool get(); void set(bool value); };" />
<MemberType>Property</MemberType>
<Implements>
<InterfaceMember>P:System.Runtime.Remoting.Channels.ISecurableChannel.IsSecured</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Boolean</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets or sets a Boolean value that indicates whether the current channel is secure.</summary>
<value>A Boolean value that indicates whether the current instance is secure.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
This property need not be set explicitly, as it is sufficient to set the ensureSecurity parameter of <xref:System.Runtime.Remoting.RemotingConfiguration.Configure%28System.String%2CSystem.Boolean%29>.
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="Parse">
<MemberSignature Language="C#" Value="public string Parse (string url, out string objectURI);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance string Parse(string url, [out] string& objectURI) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.Parse(System.String,System.String@)" />
<MemberSignature Language="VB.NET" Value="Public Function Parse (url As String, ByRef objectURI As String) As String" />
<MemberSignature Language="F#" Value="abstract member Parse : string * string -> string
override this.Parse : string * string -> string" Usage="tcpChannel.Parse (url, objectURI)" />
<MemberSignature Language="C++ CLI" Value="public:
 virtual System::String ^ Parse(System::String ^ url, [Runtime::InteropServices::Out] System::String ^ % objectURI);" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Runtime.Remoting.Channels.IChannel.Parse(System.String,System.String@)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.String</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="url" Type="System.String" />
<Parameter Name="objectURI" Type="System.String" RefType="out" />
</Parameters>
<Docs>
<param name="url">The URL from which to extract the URI of the remote well-known object.</param>
<param name="objectURI">When this method returns, contains a <see cref="T:System.String" /> that holds the URI of the remote well-known object. This parameter is passed uninitialized.</param>
<summary>Extracts the channel URI and the remote well-known object URI from the specified URL.</summary>
<returns>The URI of the current channel.</returns>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
A URI of an object is a value that uniquely identifies a specific object instance.
## Examples
The following code example shows how to use this method.
:::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Runtime.Remoting.Channels.Tcp.TcpChannel/CPP/server.cpp" id="Snippet6":::
:::code language="csharp" source="~/snippets/csharp/System.Runtime.Remoting.Channels.Tcp/TcpChannel/Overview/server.cs" id="Snippet6":::
]]></format>
</remarks>
<altmember cref="T:System.Uri" />
</Docs>
</Member>
<Member MemberName="StartListening">
<MemberSignature Language="C#" Value="public void StartListening (object data);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance void StartListening(object data) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.StartListening(System.Object)" />
<MemberSignature Language="VB.NET" Value="Public Sub StartListening (data As Object)" />
<MemberSignature Language="F#" Value="abstract member StartListening : obj -> unit
override this.StartListening : obj -> unit" Usage="tcpChannel.StartListening data" />
<MemberSignature Language="C++ CLI" Value="public:
 virtual void StartListening(System::Object ^ data);" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Runtime.Remoting.Channels.IChannelReceiver.StartListening(System.Object)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="data" Type="System.Object" />
</Parameters>
<Docs>
<param name="data">Optional initialization information.</param>
<summary>Instructs the current channel to start listening for requests.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
It is not necessary to call this method to begin listening on a newly initialized channel.
Use this method to restart listening on a channel after the <xref:System.Runtime.Remoting.Channels.Tcp.TcpServerChannel.StopListening%2A> method has been called.
If your channel uses a dynamically assigned port number, your port number might change when you restart listening.
The `data` parameter can be used to pass a specific initialization state to the channel. If you do not want to pass a specific state to the channel, set `data` to `null`.
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="StopListening">
<MemberSignature Language="C#" Value="public void StopListening (object data);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance void StopListening(object data) cil managed" />
<MemberSignature Language="DocId" Value="M:System.Runtime.Remoting.Channels.Tcp.TcpChannel.StopListening(System.Object)" />
<MemberSignature Language="VB.NET" Value="Public Sub StopListening (data As Object)" />
<MemberSignature Language="F#" Value="abstract member StopListening : obj -> unit
override this.StopListening : obj -> unit" Usage="tcpChannel.StopListening data" />
<MemberSignature Language="C++ CLI" Value="public:
 virtual void StopListening(System::Object ^ data);" />
<MemberType>Method</MemberType>
<Implements>
<InterfaceMember>M:System.Runtime.Remoting.Channels.IChannelReceiver.StopListening(System.Object)</InterfaceMember>
</Implements>
<AssemblyInfo>
<AssemblyName>System.Runtime.Remoting</AssemblyName>
<AssemblyVersion>1.0.5000.0</AssemblyVersion>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="data" Type="System.Object" />
</Parameters>
<Docs>
<param name="data">Optional state information for the channel.</param>
<summary>Instructs the current channel to stop listening for requests.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
Use this method to stop listening on a channel. To restart listening, use the <xref:System.Runtime.Remoting.Channels.Tcp.TcpServerChannel.StartListening%2A> method.
If your channel uses a dynamically assigned port number, your port number might change when you restart listening.
The `data` parameter can be used to pass a specific initialization state to the channel. If you do not want to pass a specific state to the channel, set `data` to `null`.
]]></format>
</remarks>
</Docs>
</Member>
</Members>
</Type>