Adds an item to the list.
procedure PushItem(AItem: Pointer); override;
virtual __fastcall PushItem(void * AItem);
The protected PushItem method provides the underlying implementation for the Push method. In TOrderedList, PushItem has no implementation (it is abstract or, in C++ terminology, pure virtual).
Descendant classes override this method to add items to the list specified by the List property. Each descendant class adds items so as to maintain the list in reverse output order. In TStack, items are added to the end of the list (so that the list is last-in first-out). In TQueue, items are added to the beginning (so that the list is first-in first-out).
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!