Class TLListInt (unit Llistint)

Inherits from

TComponent

Constructors


constructor create(AOwner: TComponent);

Public-Deklarationen

set up the TLListInt object with default values



Functions

procedure Add(newItem: TData);

insert cell at bottom of list

function Delete(Index: integer): Boolean;

delete the current cell

destructor destroy;

destroy the entire list, cell by cell

function FindFirst(cmpItem: TData): integer;

Look for item in data field.

function FindNext(cmpItem: TData): integer;

Look for item in data field.

function Insert(newItem: TData; Index: integer): Boolean;

insert cell before item[Index]

function GetItem(Index: Integer): TData;

make current the absolute cell N in the list } { where top = 0 } { return data item from current list position

procedure SetItem(Index: Integer; newData:TData);

make current the absolute cell N in the list } { where top = 0 } { set data item to current list position

function SetItemIndex(Position: Integer): Boolean;

make current the absolute cell at Position in the list } { where top = 0

Properties

property Item : TData


property ItemCount : integer


property ItemIndex : integer


Events

Variables

bottom : CellPtr;


current : CellPtr;


FCurrPos : integer;


FSize : integer;


top : CellPtr;

Private-Deklarationen


Constructors


constructor create(AOwner: TComponent);

Public-Deklarationen

set up the TLListInt object with default values


Functions


procedure Add(newItem: TData);

insert cell at bottom of list


function Delete(Index: integer): Boolean;

delete the current cell


destructor destroy;

destroy the entire list, cell by cell


function FindFirst(cmpItem: TData): integer;

Look for item in data field. Starts at top of list } { and looks at every item until a match is found. } { if found, makes matched cell current, and returns } { absolute location of match where 0 = top. } { if not found returns -1


function FindNext(cmpItem: TData): integer;

Look for item in data field. Starts at current^.next} { and looks at every item until a match is found. } { if found, makes matched cell current, and returns } { absolute location of match where 0 = top. } { if not found, returns -1


function Insert(newItem: TData; Index: integer): Boolean;

insert cell before item[Index]


function GetItem(Index: Integer): TData;

make current the absolute cell N in the list } { where top = 0 } { return data item from current list position


procedure SetItem(Index: Integer; newData:TData);

make current the absolute cell N in the list } { where top = 0 } { set data item to current list position


function SetItemIndex(Position: Integer): Boolean;

make current the absolute cell at Position in the list } { where top = 0


Properties


property Item : TData


property ItemCount : integer


property ItemIndex : integer


Events


Variables


bottom : CellPtr;


current : CellPtr;


FCurrPos : integer;


FSize : integer;


top : CellPtr;

Private-Deklarationen