API:System.Tether.TCPProtocol.TTetheringTCPProtocol.CreateInstance
Delphi
class function CreateInstance(const AnAdapter: TTetheringAdapter; AsClient: Boolean): TTetheringProtocol; override;
C++
__classmethod virtual System::Tether::Manager::TTetheringProtocol* __fastcall CreateInstance(System::Tether::Manager::TTetheringAdapter* const AnAdapter, bool AsClient);
プロパティ
種類 | 可視性 | ソース | ユニット | 親 |
---|---|---|---|---|
function | public | System.Tether.TCPProtocol.pas System.Tether.TCPProtocol.hpp |
System.Tether.TCPProtocol | TTetheringTCPProtocol |
説明
System.Tether.TCPProtocol.TTetheringTCPProtocol.CreateInstance は System.Tether.Manager.TTetheringProtocol.CreateInstance を継承しています。以下の内容はすべて System.Tether.Manager.TTetheringProtocol.CreateInstance を参照しています。
CreateInstance は、次のパラメータを受け取ります:
AnAdapter
は、プロトコールがピア間に接続を確立するのに必要な情報を取得するために使用するアダプタです。AsClient
は、TTetheringProtocol のこのインスタンスが処理する接続のエンドが、クライアント(True
)として動作するのか、サーバー(False
、デフォルト)として動作するのかを判断します。
これは、抽象メソッドです。 TTetheringProtocol のサブクラスを作成する場合には、この関数をオーバーライドしなければなりません。