Functions
xmlSecPtrListSetDefaultAllocMode ()
void
xmlSecPtrListSetDefaultAllocMode (xmlSecAllocMode defAllocMode
,
xmlSecSize defInitialSize
);
Sets new default allocation mode and minimal initial list size.
xmlSecPtrListInitialize ()
int
xmlSecPtrListInitialize (xmlSecPtrListPtr list
,
xmlSecPtrListId id
);
Initializes the list of given klass. Caller is responsible
for cleaning up by calling xmlSecPtrListFinalize function.
Returns
0 on success or a negative value if an error occurs.
xmlSecPtrListCreate ()
xmlSecPtrListPtr
xmlSecPtrListCreate (xmlSecPtrListId id
);
Creates new list object. Caller is responsible for freeing returned list
by calling xmlSecPtrListDestroy function.
Returns
pointer to newly allocated list or NULL if an error occurs.
xmlSecPtrListEmpty ()
void
xmlSecPtrListEmpty (xmlSecPtrListPtr list
);
Remove all items from list
(if any).
xmlSecPtrListCopy ()
int
xmlSecPtrListCopy (xmlSecPtrListPtr dst
,
xmlSecPtrListPtr src
);
Copies src
list items to dst
list using duplicateItem method
of the list klass. If duplicateItem method is NULL then
we jsut copy pointers to items.
Returns
0 on success or a negative value if an error occurs.
xmlSecPtrListDuplicate ()
xmlSecPtrListPtr
xmlSecPtrListDuplicate (xmlSecPtrListPtr list
);
Creates a new copy of list
and all its items.
Returns
pointer to newly allocated list or NULL if an error occurs.
xmlSecPtrListGetSize ()
xmlSecSize
xmlSecPtrListGetSize (xmlSecPtrListPtr list
);
Gets list size.
Returns
the number of itmes in list
.
xmlSecPtrListGetItem ()
xmlSecPtr
xmlSecPtrListGetItem (xmlSecPtrListPtr list
,
xmlSecSize pos
);
Gets item from the list.
Returns
the list item at position pos
or NULL if pos
is greater
than the number of items in the list or an error occurs.
xmlSecPtrListAdd ()
int
xmlSecPtrListAdd (xmlSecPtrListPtr list
,
xmlSecPtr item
);
Adds item
to the end of the list
.
Returns
0 on success or a negative value if an error occurs.
xmlSecPtrListSet ()
int
xmlSecPtrListSet (xmlSecPtrListPtr list
,
xmlSecPtr item
,
xmlSecSize pos
);
Sets the value of list item at position pos
. The old value
is destroyed.
Returns
0 on success or a negative value if an error occurs.
xmlSecPtrListRemove ()
int
xmlSecPtrListRemove (xmlSecPtrListPtr list
,
xmlSecSize pos
);
Destroys list item at the position pos
and sets it value to NULL.
Returns
0 on success or a negative value if an error occurs.
xmlSecPtrListRemoveAndReturn ()
xmlSecPtr
xmlSecPtrListRemoveAndReturn (xmlSecPtrListPtr list
,
xmlSecSize pos
);
Remove the list item at the position pos
and return it back.
Returns
the pointer to the list item.
xmlSecPtrListDebugDump ()
void
xmlSecPtrListDebugDump (xmlSecPtrListPtr list
,
FILE *output
);
Prints debug information about list
to the output
.
xmlSecPtrListDebugXmlDump ()
void
xmlSecPtrListDebugXmlDump (xmlSecPtrListPtr list
,
FILE *output
);
Prints debug information about list
to the output
in XML format.
xmlSecPtrListGetName()
#define xmlSecPtrListGetName(list)
Macro. Returns lists's name.
xmlSecPtrListIsValid()
#define xmlSecPtrListIsValid(list)
Macro. Returns 1 if list
is not NULL and list->id
is not NULL
or 0 otherwise.
xmlSecPtrListCheckId()
#define xmlSecPtrListCheckId(list, dataId)
Macro. Returns 1 if list
is valid and list
's id is equal to dataId
.
xmlSecPtrDuplicateItemMethod ()
xmlSecPtr
(*xmlSecPtrDuplicateItemMethod) (xmlSecPtr ptr
);
Duplicates item ptr
.
Returns
pointer to new item copy or NULL if an error occurs.
xmlSecPtrDestroyItemMethod ()
void
(*xmlSecPtrDestroyItemMethod) (xmlSecPtr ptr
);
Destroys list item ptr
.
xmlSecPtrDebugDumpItemMethod ()
void
(*xmlSecPtrDebugDumpItemMethod) (xmlSecPtr ptr
,
FILE *output
);
Prints debug information about item
to output
.
xmlSecPtrListKlassGetName()
#define xmlSecPtrListKlassGetName(klass)
Macro. Returns the list klass name.
xmlSecStringListGetKlass ()
xmlSecPtrListId
xmlSecStringListGetKlass (void
);
The strins list class.
Returns
strings list klass.