API:System.Contnrs.TComponentList.IndexOfItem
Delphi
function IndexOfItem(AComponent: TComponent; ADirection: TList.TDirection): NativeInt; inline;
C++
HIDESBASE System::NativeInt __fastcall IndexOfItem(System::Classes::TComponent* AComponent, System::Types::TDirection ADirection);
プロパティ
種類 | 可視性 | ソース | ユニット | 親 |
---|---|---|---|---|
function | public | System.Contnrs.pas System.Contnrs.hpp |
System.Contnrs | TComponentList |
説明
項目のインデックスを返します。
System.Contnrs.TComponentList.IndexOfItem は System.Classes.TList.IndexOfItem を継承しています。以下の内容はすべて System.Classes.TList.IndexOfItem を参照しています。
項目のインデックスを返します。
IndexOfItem メソッドを呼び出すと、リニア検索を使用して TList リストにある項目の場所を決定できます。 項目が見つからない場合は、-1 を返します。