System.Generics.Collections.TList.Create

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

constructor Create; overload;
constructor Create(const AComparer: IComparer<T>); overload;
constructor Create(const Collection: TEnumerable<T>); overload;
constructor Create(const Collection: IEnumerable<T>); overload;
constructor Create(const Values: array of T); overload;

C++

__fastcall TList__1()/* overload */;
__fastcall TList__1(const System::DelphiInterface<System::Generics::Defaults::IComparer__1<T> > AComparer)/* overload */;
__fastcall TList__1(TEnumerable__1<T>* const Collection)/* overload */;
__fastcall TList__1(const System::DelphiInterface<System::IEnumerable__1<T> > Collection)/* overload */;
__fastcall TList__1(const T *Values, const System::NativeInt Values_High)/* overload */;

Properties

Type Visibility Source Unit Parent
constructor public
System.Generics.Collections.pas
System.Generics.Collections.hpp
System.Generics.Collections TList

Description

Create and initialize a list instance.

This overloaded method creates and initializes a list instance.

AComparer is a comparison function. If not provided, the default comparator for the type is used.

Collection is a collection with which to initialize the list. The objects are added in the same order as in Collection. If Collection is specified, the creation is an O(n) operation, where n is the number of items in Collection.

See Also