Porovnávané verzie

Kľúč

  • Tento riadok sa pridal
  • Riadok je odstránený.
  • Formátovanie sa zmenilo.

InsertEl


Declaration
void (_stdcall *InsertEl)(LinListH List, void *DataPtr, void *SortProc);
Parameters


ListHandle to a linear list.
DataPtrAddress of inserted data, which are allocated by calling the call-back function GetMem.
SortProcAddress of sort function. If the function is not used, there will be inserted the value NULL. The item is then inserted at the beginning of the list.
Description

The function inserts an item into a linear list.

Note

The form of a sort function:

Blok kódu
languageesl
themeConfluence
int _stdcall SortProc(void *El1, void *El2)

Where El1 is the address of inserted item and El2 is the address of an item in the list. The sort function is used to compare elements during inserting. It starts from the beginning of the list and inserted item is inserted in front of given item if the return code is greater or equal to zero.


Info
titleRelated pages:

D2000 KomAPI - call-back functions