System.Tether.Manager.TTetheringProtocols.GetProtocolInstance

De RAD Studio API Documentation
Aller à : navigation, rechercher

Delphi

class function GetProtocolInstance(const AProtocolType: TTetheringProtocolType; const AnAdapter: TTetheringAdapter;  AsClient, Started: Boolean): TTetheringProtocol;

C++

__classmethod TTetheringProtocol* __fastcall GetProtocolInstance(const System::UnicodeString AProtocolType, TTetheringAdapter* const AnAdapter, bool AsClient, bool Started);

Propriétés

Type Visibilité  Source Unité  Parent
function public
System.Tether.Manager.pas
System.Tether.Manager.hpp
System.Tether.Manager TTetheringProtocols


Description

Crée et renvoie une instance d'un protocole du type spécifié.

S'il n'existe aucun protocole recensé avec AProtocolType, GetProtocolInstance renvoie null.

AsClient détermine si l'instance créée doit fonctionner en tant que client seulement (True) ou en tant que client et serveur en même temps (False).

Exceptions

Si Started vaut True, voir TTetheringTCPProtocol.StartCommunication pour des informations sur les exceptions pouvant se déclencher quand vous appelez GetProtocolInstance pour obtenir une instance de TTetheringTCPProtocol.

Voir aussi