System.Tether.Manager.TTetheringProtocols.GetProtocolInstance
Delphi
class function GetProtocolInstance(const AProfile: TTetheringProfile; const AProtocolType: TTetheringProtocolType; const AnAdapter: TTetheringAdapter; AsClient: Boolean): TTetheringProtocol;
C++
__classmethod TTetheringProtocol* __fastcall GetProtocolInstance(TTetheringProfile* const AProfile, const System::UnicodeString AProtocolType, TTetheringAdapter* const AnAdapter, bool AsClient);
プロパティ
| 種類 | 可視性 | ソース | ユニット | 親 |
|---|---|---|---|---|
| function | public | System.Tether.Manager.pas System.Tether.Manager.hpp |
System.Tether.Manager | TTetheringProtocols |
説明
指定されたタイプのプロトコルのインスタンスを作成して返します。
AProtocolType で登録されているプロトコルがない場合、GetProtocolInstance は null を返します。
AsClient は、作成されたインスタンスが、クライアントとしてのみ動作するべきか(True)、または、クライアントおよびサーバーとして(False)なのかを、決定します。
例外
Started が True の場合、TTetheringTCPProtocol のインスタンスを取得するために GetProtocolInstance を呼び出した際に発生する可能性のある例外については、TTetheringTCPProtocol.StartCommunication を参照してください。