Skip to content

TInterfaceList

Standard implementation of the IInterfaceList interface.

Declaration

Source position: classesh.inc line 2848

type

  TInterfaceList = class(TInterfacedObject, IInterfaceList, IInterfaceListEx)
  public
    constructor Create;
    destructor Destroy;
    procedure Clear;
    procedure Delete;
    procedure Exchange;
    function First : IUnknown;
    function GetEnumerator : TInterfaceListEnumerator;
    function IndexOf : Integer;
    function Add : Integer;
    procedure Insert;
    function Last : IUnknown;
    function Remove : Integer;
    procedure Lock;
    procedure Unlock;
    function Expand : TInterfaceList;
    property Capacity: Integer; {rw}
    property Count: Integer; {rw}
    property Items[Index : Integer]: IUnknown; {rw}
  end;

Description

TInterfaceList is a standard implementation of the IInterfaceList interface. It uses a TThreadList instance to store the list of interfaces.

Properties

Member Visibility Description
Capacity public The current capacity of the list.
Count public The current number of elements in the list.
Items public Array-based access to the list's items.
See all Properties

Methods

Member Visibility Description
Add public Add an interface to the list.
Clear public Removes all interfaces from the list.
Create public Create a new instance of TInterfaceList.
Delete public Delete an interface from the list.
Destroy public Destroys the list of interfaces.
Exchange public Exchange 2 interfaces in the list.
Expand public Expands the list.
First public Returns the first non-Nil element in the list.
GetEnumerator public Create an IEnumerator instance.
IndexOf public Returns the index of an interface.
Insert public Insert an interface to the list.
Last public Returns the last non-Nil element in the list.
Lock public Lock the list.
Remove public Remove an interface from the list.
Unlock public UnLocks a locked list.
See all Methods

See also

Name Description
IInterfaceList Interface for maintaining a list of interfaces.
TList Class to manage collections of pointers.