gdsl
1.7
|
Go to the source code of this file.
Typedefs | |
typedef struct _gdsl_list * | gdsl_list_t |
GDSL doubly-linked list type. | |
typedef struct _gdsl_list_cursor * | gdsl_list_cursor_t |
GDSL doubly-linked list cursor type. | |
Functions | |
gdsl_list_t | gdsl_list_alloc (const char *NAME, gdsl_alloc_func_t ALLOC_F, gdsl_free_func_t FREE_F) |
Create a new list. | |
void | gdsl_list_free (gdsl_list_t L) |
Destroy a list. | |
void | gdsl_list_flush (gdsl_list_t L) |
Flush a list. | |
const char * | gdsl_list_get_name (const gdsl_list_t L) |
Get the name of a list. | |
ulong | gdsl_list_get_size (const gdsl_list_t L) |
Get the size of a list. | |
bool | gdsl_list_is_empty (const gdsl_list_t L) |
Check if a list is empty. | |
gdsl_element_t | gdsl_list_get_head (const gdsl_list_t L) |
Get the head of a list. | |
gdsl_element_t | gdsl_list_get_tail (const gdsl_list_t L) |
Get the tail of a list. | |
gdsl_list_t | gdsl_list_set_name (gdsl_list_t L, const char *NEW_NAME) |
Set the name of a list. | |
gdsl_element_t | gdsl_list_insert_head (gdsl_list_t L, void *VALUE) |
Insert an element at the head of a list. | |
gdsl_element_t | gdsl_list_insert_tail (gdsl_list_t L, void *VALUE) |
Insert an element at the tail of a list. | |
gdsl_element_t | gdsl_list_remove_head (gdsl_list_t L) |
Remove the head of a list. | |
gdsl_element_t | gdsl_list_remove_tail (gdsl_list_t L) |
Remove the tail of a list. | |
gdsl_element_t | gdsl_list_remove (gdsl_list_t L, gdsl_compare_func_t COMP_F, const void *VALUE) |
Remove a particular element from a list. | |
gdsl_list_t | gdsl_list_delete_head (gdsl_list_t L) |
Delete the head of a list. | |
gdsl_list_t | gdsl_list_delete_tail (gdsl_list_t L) |
Delete the tail of a list. | |
gdsl_list_t | gdsl_list_delete (gdsl_list_t L, gdsl_compare_func_t COMP_F, const void *VALUE) |
Delete a particular element from a list. | |
gdsl_element_t | gdsl_list_search (const gdsl_list_t L, gdsl_compare_func_t COMP_F, const void *VALUE) |
Search for a particular element into a list. | |
gdsl_element_t | gdsl_list_search_by_position (const gdsl_list_t L, ulong POS) |
Search for an element by its position in a list. | |
gdsl_element_t | gdsl_list_search_max (const gdsl_list_t L, gdsl_compare_func_t COMP_F) |
Search for the greatest element of a list. | |
gdsl_element_t | gdsl_list_search_min (const gdsl_list_t L, gdsl_compare_func_t COMP_F) |
Search for the lowest element of a list. | |
gdsl_list_t | gdsl_list_sort (gdsl_list_t L, gdsl_compare_func_t COMP_F) |
Sort a list. | |
gdsl_element_t | gdsl_list_map_forward (const gdsl_list_t L, gdsl_map_func_t MAP_F, void *USER_DATA) |
Parse a list from head to tail. | |
gdsl_element_t | gdsl_list_map_backward (const gdsl_list_t L, gdsl_map_func_t MAP_F, void *USER_DATA) |
Parse a list from tail to head. | |
void | gdsl_list_write (const gdsl_list_t L, gdsl_write_func_t WRITE_F, FILE *OUTPUT_FILE, void *USER_DATA) |
Write all the elements of a list to a file. | |
void | gdsl_list_write_xml (const gdsl_list_t L, gdsl_write_func_t WRITE_F, FILE *OUTPUT_FILE, void *USER_DATA) |
Write the content of a list to a file into XML. | |
void | gdsl_list_dump (const gdsl_list_t L, gdsl_write_func_t WRITE_F, FILE *OUTPUT_FILE, void *USER_DATA) |
Dump the internal structure of a list to a file. | |
gdsl_list_cursor_t | gdsl_list_cursor_alloc (const gdsl_list_t L) |
Create a new list cursor. | |
void | gdsl_list_cursor_free (gdsl_list_cursor_t C) |
Destroy a list cursor. | |
void | gdsl_list_cursor_move_to_head (gdsl_list_cursor_t C) |
Put a cursor on the head of its list. | |
void | gdsl_list_cursor_move_to_tail (gdsl_list_cursor_t C) |
Put a cursor on the tail of its list. | |
gdsl_element_t | gdsl_list_cursor_move_to_value (gdsl_list_cursor_t C, gdsl_compare_func_t COMP_F, void *VALUE) |
Place a cursor on a particular element. | |
gdsl_element_t | gdsl_list_cursor_move_to_position (gdsl_list_cursor_t C, ulong POS) |
Place a cursor on a element given by its position. | |
void | gdsl_list_cursor_step_forward (gdsl_list_cursor_t C) |
Move a cursor one step forward of its list. | |
void | gdsl_list_cursor_step_backward (gdsl_list_cursor_t C) |
Move a cursor one step backward of its list. | |
bool | gdsl_list_cursor_is_on_head (const gdsl_list_cursor_t C) |
Check if a cursor is on the head of its list. | |
bool | gdsl_list_cursor_is_on_tail (const gdsl_list_cursor_t C) |
Check if a cursor is on the tail of its list. | |
bool | gdsl_list_cursor_has_succ (const gdsl_list_cursor_t C) |
Check if a cursor has a successor. | |
bool | gdsl_list_cursor_has_pred (const gdsl_list_cursor_t C) |
Check if a cursor has a predecessor. | |
void | gdsl_list_cursor_set_content (gdsl_list_cursor_t C, gdsl_element_t E) |
Set the content of the cursor. | |
gdsl_element_t | gdsl_list_cursor_get_content (const gdsl_list_cursor_t C) |
Get the content of a cursor. | |
gdsl_element_t | gdsl_list_cursor_insert_after (gdsl_list_cursor_t C, void *VALUE) |
Insert a new element after a cursor. | |
gdsl_element_t | gdsl_list_cursor_insert_before (gdsl_list_cursor_t C, void *VALUE) |
Insert a new element before a cursor. | |
gdsl_element_t | gdsl_list_cursor_remove (gdsl_list_cursor_t C) |
Removec the element under a cursor. | |
gdsl_element_t | gdsl_list_cursor_remove_after (gdsl_list_cursor_t C) |
Removec the element after a cursor. | |
gdsl_element_t | gdsl_list_cursor_remove_before (gdsl_list_cursor_t C) |
Remove the element before a cursor. | |
gdsl_list_cursor_t | gdsl_list_cursor_delete (gdsl_list_cursor_t C) |
Delete the element under a cursor. | |
gdsl_list_cursor_t | gdsl_list_cursor_delete_after (gdsl_list_cursor_t C) |
Delete the element after a cursor. | |
gdsl_list_cursor_t | gdsl_list_cursor_delete_before (gdsl_list_cursor_t C) |
Delete the element before the cursor of a list. |