create_aList (ul_oocbs)
aList.s.r = create_aList()
This function is used as a constructor to create an instance of
the aList class. This class is used to provide an object-oriented
interface to a heterogenous aList datatype.
This function returns:
a pointer to the newly-created instance of the aList class upon
success, or a null pointer upon failure to allocate virtual memory.
Use of this class requires the following header files:
aList.h
Methods for aList:
destroy destructor for the aList class
free used to tell an instance of the aList class to free
all of the virtual memory it has allocated. This is
primarily provided to support derived classes; most
application programs should NOT call this method.
Only use this method if you really know what you are
doing.
clone used to clone an instance of a aList class, to make
another identical instance of a aList class,
including all data. This method does its own
allocation and copying of all stored data items, so
the cloned aList is truly independent of the aList
from which it was created.
put insert an item at the tail of the aList
get remove an item from the head of the aList
get_length find out how many items are stored in the aList
retrieve retrieve a copy the item specified by the given tag,
leaving the original item in the aList
retrieve_last retrieve a copy the item specified by the given tag,
leaving the original item in the aList
remove remove the item specified by the given tag
insert_after_tag insert an item into the aList after the item
corresponding to the specified tag
insert_after_element insert an item into the aList after the item
with the specified position in the aList
update change the value of the item with the specified tag
reset reset the aList's internal iteration pointer to
point to the beginning of the aList
get_next remove the "next" item from the aList
C/C++ usage:
#include "aList.h"
aList* aList;
aList = create_aList();