ChannelServices.RegisteredChannels Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets a list of currently registered channels.

Namespace:   System.Runtime.Remoting.Channels
Assembly:  mscorlib (in mscorlib.dll)

public static IChannel[] RegisteredChannels {
	[SecurityCriticalAttribute]
	get;
}

Property Value

Type: System.Runtime.Remoting.Channels.IChannel[]

An array of all the currently registered channels.

Exception Condition
SecurityException

The immediate caller does not have infrastructure permission.

// Retrieve and print information about the registered channels.
IChannel[] myIChannelArray = ChannelServices.RegisteredChannels;
for (int i=0; i<myIChannelArray.Length; i++)
{
   Console.WriteLine("Name of Channel: {0}", myIChannelArray[i].ChannelName);
   Console.WriteLine("Priority of Channel: {0}",
      +myIChannelArray[i].ChannelPriority);
}

SecurityPermission

For operating with infrastructure code. Demand value: SecurityAction.LinkDemand; Permission value: SecurityPermissionFlag.Infrastructure

.NET Framework
Available since 1.1
Return to top
Show: