TcpServerChannel.ChannelData Propriété
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Obtient des données spécifiques au canal.
public:
property System::Object ^ ChannelData { System::Object ^ get(); };
public object ChannelData { get; }
member this.ChannelData : obj
Public ReadOnly Property ChannelData As Object
Valeur de propriété
Instance ChannelDataStore contenant des données spécifiques au canal.
Implémente
Exemples
L’exemple de code suivant montre l’utilisation de cette propriété.
// Show the URIs associated with the channel.
ChannelDataStore^ data = dynamic_cast<ChannelDataStore^>(serverChannel->ChannelData);
System::Collections::IEnumerator^ myEnum = data->ChannelUris->GetEnumerator();
while ( myEnum->MoveNext() )
{
String^ uri = safe_cast<String^>(myEnum->Current);
Console::WriteLine( uri );
}
// Show the URIs associated with the channel.
ChannelDataStore data = (ChannelDataStore) serverChannel.ChannelData;
foreach (string uri in data.ChannelUris)
{
Console.WriteLine(uri);
}
Remarques
Bien qu’elle soit retournée en tant qu’instance de System.Object, la valeur de cette propriété peut être castée en une instance de ChannelDataStore description du canal vers lequel l’objet TcpServerChannel écoute.