ReactOS 0.4.16-dev-197-g92996da
|
#include "libxml.h"
#include <stdlib.h>
#include <string.h>
#include <libxml/xmlmemory.h>
#include <libxml/list.h>
#include <libxml/globals.h>
Go to the source code of this file.
Classes | |
struct | _xmlLink |
struct | _xmlList |
Macros | |
#define | IN_LIBXML |
xmlLinkCompare: @data0: first data @data1: second data
Compares two arbitrary data
Returns -1, 0 or 1 depending on whether data1 is greater equal or smaller than data0
Definition at line 79 of file list.c.
Referenced by xmlListCreate().
|
static |
xmlLinkDeallocator: @l: a list @lk: a link
Unlink and deallocate @lk from list @l
Definition at line 59 of file list.c.
Referenced by xmlListClear(), xmlListPopBack(), xmlListPopFront(), xmlListRemoveFirst(), and xmlListRemoveLast().
void * xmlLinkGetData | ( | xmlLinkPtr | lk | ) |
xmlLinkGetData: @lk: a link
See Returns.
Returns a pointer to the data referenced from this link
Definition at line 604 of file list.c.
Referenced by xmlFreeRef().
int xmlListAppend | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListAppend: @l: a list @data: the data
Insert data in the ordered list at the end for this value
Returns 0 in case of success, 1 in case of failure
Definition at line 305 of file list.c.
Referenced by xmlAddRef().
void xmlListClear | ( | xmlListPtr | l | ) |
xmlListClear: @l: a list
Remove the all data in the list
Definition at line 422 of file list.c.
Referenced by xmlListDelete(), xmlListMerge(), and xmlListSort().
int xmlListCopy | ( | xmlListPtr | cur, |
const xmlListPtr | old | ||
) |
xmlListCopy: @cur: the new list @old: the old list
Move all the element from the old list in the new list
Returns 0 in case of success 1 in case of error
Definition at line 761 of file list.c.
Referenced by xmlListDup(), and xmlListMerge().
xmlListPtr xmlListCreate | ( | xmlListDeallocator | deallocator, |
xmlListDataCompare | compare | ||
) |
xmlListCreate: @deallocator: an optional deallocator function @compare: an optional comparison function
Create a new list
Returns the new list or NULL in case of error
Definition at line 188 of file list.c.
Referenced by xmlAddRef(), and xmlListDup().
void xmlListDelete | ( | xmlListPtr | l | ) |
xmlListDelete: @l: a list
Deletes the list and its associated data
Definition at line 333 of file list.c.
Referenced by xmlAddRef(), xmlFreeRefTableEntry(), xmlListCopy(), and xmlListSort().
xmlListPtr xmlListDup | ( | const xmlListPtr | old | ) |
xmlListDup: @old: the list
Duplicate the list
Returns a new copy of the list or NULL in case of error
Definition at line 732 of file list.c.
Referenced by xmlListSort().
int xmlListEmpty | ( | xmlListPtr | l | ) |
xmlListEmpty: @l: a list
Is the list empty ?
Returns 1 if the list is empty, 0 if not empty and -1 in case of error
Definition at line 446 of file list.c.
Referenced by xmlListPopBack(), xmlListPopFront(), xmlListSort(), and xmlRemoveRef().
xmlLinkPtr xmlListEnd | ( | xmlListPtr | l | ) |
xmlLinkPtr xmlListFront | ( | xmlListPtr | l | ) |
|
static |
xmlListHigherSearch: @l: a list @data: a data
Search data in the ordered list walking backward from the end
Returns the link containing the data or NULL
Definition at line 118 of file list.c.
Referenced by xmlListAppend(), and xmlListLinkReverseSearch().
int xmlListInsert | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListInsert: @l: a list @data: the data
Insert data in the ordered list at the beginning for this value
Returns 0 in case of success, 1 in case of failure
Definition at line 273 of file list.c.
Referenced by xmlListCopy().
|
static |
xmlListLinkReverseSearch: @l: a list @data: a data
Search data in the list processing backward
Returns the link containing the data or NULL
Definition at line 163 of file list.c.
Referenced by xmlListRemoveLast(), and xmlListReverseSearch().
|
static |
xmlListSearch: @l: a list @data: a data
Search data in the list
Returns the link containing the data or NULL
Definition at line 138 of file list.c.
Referenced by xmlListRemoveFirst(), and xmlListSearch().
|
static |
xmlListLowerSearch: @l: a list @data: a data
Search data in the ordered list walking from the beginning
Returns the link containing the data or NULL
Definition at line 98 of file list.c.
Referenced by xmlListInsert(), and xmlListLinkSearch().
void xmlListMerge | ( | xmlListPtr | l1, |
xmlListPtr | l2 | ||
) |
xmlListMerge: @l1: the original list @l2: the new list
include all the elements of the second list in the first one and clear the second list
Definition at line 717 of file list.c.
Referenced by xmlListSort().
void xmlListPopBack | ( | xmlListPtr | l | ) |
void xmlListPopFront | ( | xmlListPtr | l | ) |
xmlListPopFront: @l: a list
Removes the first element in the list
int xmlListPushBack | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListPushBack: @l: a list @data: new data
add the new data at the end of the list
Returns 1 if successful, 0 otherwise
Definition at line 574 of file list.c.
int xmlListPushFront | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListPushFront: @l: a list @data: new data
add the new data at the beginning of the list
Returns 1 if successful, 0 otherwise
Definition at line 542 of file list.c.
int xmlListRemoveAll | ( | xmlListPtr | l, |
void * | data | ||
) |
int xmlListRemoveFirst | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListRemoveFirst: @l: a list @data: list data
Remove the first instance associated to data in the list
Returns 1 if a deallocation occurred, or 0 if not found
Definition at line 353 of file list.c.
Referenced by xmlListRemoveAll(), and xmlWalkRemoveRef().
int xmlListRemoveLast | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListRemoveLast: @l: a list @data: list data
Remove the last instance associated to data in the list
Returns 1 if a deallocation occurred, or 0 if not found
Definition at line 378 of file list.c.
void xmlListReverse | ( | xmlListPtr | l | ) |
xmlListReverse: @l: a list
Reverse the order of the elements in the list
Definition at line 618 of file list.c.
void * xmlListReverseSearch | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListReverseSearch: @l: a list @data: a search value
Search the list in reverse order for an existing value of @data
Returns the value associated to @data or NULL in case of error
void xmlListReverseWalk | ( | xmlListPtr | l, |
xmlListWalker | walker, | ||
void * | user | ||
) |
xmlListReverseWalk: @l: a list @walker: a processing function @user: a user parameter passed to the walker function
Walk all the element of the list in reverse order and apply the walker function to it
void * xmlListSearch | ( | xmlListPtr | l, |
void * | data | ||
) |
xmlListSearch: @l: a list @data: a search value
Search the list for an existing value of @data
Returns the value associated to @data or NULL in case of error
int xmlListSize | ( | xmlListPtr | l | ) |
xmlListSize: @l: a list
Get the number of elements in the list
Returns the number of elements in the list or -1 in case of error
void xmlListSort | ( | xmlListPtr | l | ) |
xmlListSort: @l: a list
Sort all the elements in the list
Definition at line 643 of file list.c.
void xmlListWalk | ( | xmlListPtr | l, |
xmlListWalker | walker, | ||
void * | user | ||
) |
xmlListWalk: @l: a list @walker: a processing function @user: a user parameter passed to the walker function
Walk all the element of the first from first to last and apply the walker function to it
Definition at line 676 of file list.c.
Referenced by xmlRemoveRef().