OpENer - Open Source EtherNet/IP(TM) I/O Target Stack  2.1
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
doublylinkedlist.c File Reference
#include "doublylinkedlist.h"
#include "opener_user_conf.h"
#include <stdio.h>
#include <assert.h>
Include dependency graph for doublylinkedlist.c:

Go to the source code of this file.

Functions

void DoublyLinkedListDestroy (DoublyLinkedList *list)
 
void DoublyLinkedListInitialize (DoublyLinkedList *list, NodeMemoryAllocator allocator, NodeMemoryDeallocator deallocator)
 
void DoublyLinkedListInsertAfterNode (DoublyLinkedList *const list, DoublyLinkedListNode *node, void *data)
 
void DoublyLinkedListInsertAtHead (DoublyLinkedList *const list, void *data)
 
void DoublyLinkedListInsertAtTail (DoublyLinkedList *const list, const void *const data)
 
void DoublyLinkedListInsertBeforeNode (DoublyLinkedList *const list, DoublyLinkedListNode *node, void *data)
 
DoublyLinkedListNodeDoublyLinkedListNodeCreate (const void *const data, NodeMemoryAllocator const allocator)
 
void DoublyLinkedListNodeDestroy (const DoublyLinkedList *const list, DoublyLinkedListNode **node)
 
void DoublyLinkedListRemoveNode (DoublyLinkedList *const list, DoublyLinkedListNode **pointer_to_node_pointer)
 

Function Documentation

void DoublyLinkedListDestroy ( DoublyLinkedList list)

Definition at line 22 of file doublylinkedlist.c.

References DoublyLinkedList::allocator, DoublyLinkedList::deallocator, DoublyLinkedListNodeDestroy(), DoublyLinkedList::first, DoublyLinkedList::last, and doubly_linked_list_node::next.

Here is the call graph for this function:

void DoublyLinkedListInitialize ( DoublyLinkedList list,
NodeMemoryAllocator  allocator,
NodeMemoryDeallocator  deallocator 
)

Definition at line 13 of file doublylinkedlist.c.

References DoublyLinkedList::allocator, DoublyLinkedList::deallocator, DoublyLinkedList::first, and DoublyLinkedList::last.

Referenced by main().

Here is the caller graph for this function:

void DoublyLinkedListInsertAfterNode ( DoublyLinkedList *const  list,
DoublyLinkedListNode node,
void *  data 
)

Definition at line 97 of file doublylinkedlist.c.

References DoublyLinkedList::allocator, DoublyLinkedListInsertAtTail(), DoublyLinkedListNodeCreate(), DoublyLinkedList::last, doubly_linked_list_node::next, OPENER_ASSERT, and doubly_linked_list_node::previous.

Here is the call graph for this function:

void DoublyLinkedListInsertAtHead ( DoublyLinkedList *const  list,
void *  data 
)

Definition at line 51 of file doublylinkedlist.c.

References DoublyLinkedList::allocator, DoublyLinkedListNodeCreate(), DoublyLinkedList::first, DoublyLinkedList::last, doubly_linked_list_node::next, OPENER_ASSERT, and doubly_linked_list_node::previous.

Referenced by AddNewActiveConnection(), and DoublyLinkedListInsertBeforeNode().

Here is the call graph for this function:

Here is the caller graph for this function:

void DoublyLinkedListInsertAtTail ( DoublyLinkedList *const  list,
const void *const  data 
)

Definition at line 66 of file doublylinkedlist.c.

References DoublyLinkedList::allocator, DoublyLinkedListNodeCreate(), DoublyLinkedList::first, DoublyLinkedList::last, doubly_linked_list_node::next, OPENER_ASSERT, and doubly_linked_list_node::previous.

Referenced by DoublyLinkedListInsertAfterNode().

Here is the call graph for this function:

Here is the caller graph for this function:

void DoublyLinkedListInsertBeforeNode ( DoublyLinkedList *const  list,
DoublyLinkedListNode node,
void *  data 
)

Definition at line 81 of file doublylinkedlist.c.

References DoublyLinkedList::allocator, DoublyLinkedListInsertAtHead(), DoublyLinkedListNodeCreate(), DoublyLinkedList::first, doubly_linked_list_node::next, OPENER_ASSERT, and doubly_linked_list_node::previous.

Here is the call graph for this function:

DoublyLinkedListNode* DoublyLinkedListNodeCreate ( const void *const  data,
NodeMemoryAllocator const  allocator 
)

Definition at line 36 of file doublylinkedlist.c.

References doubly_linked_list_node::data.

Referenced by DoublyLinkedListInsertAfterNode(), DoublyLinkedListInsertAtHead(), DoublyLinkedListInsertAtTail(), and DoublyLinkedListInsertBeforeNode().

Here is the caller graph for this function:

void DoublyLinkedListNodeDestroy ( const DoublyLinkedList *const  list,
DoublyLinkedListNode **  node 
)

Definition at line 45 of file doublylinkedlist.c.

References DoublyLinkedList::deallocator, and OPENER_ASSERT.

Referenced by DoublyLinkedListDestroy(), and DoublyLinkedListRemoveNode().

Here is the caller graph for this function:

void DoublyLinkedListRemoveNode ( DoublyLinkedList *const  list,
DoublyLinkedListNode **  pointer_to_node_pointer 
)

Definition at line 113 of file doublylinkedlist.c.

References DoublyLinkedListNodeDestroy(), DoublyLinkedList::first, DoublyLinkedList::last, doubly_linked_list_node::next, and doubly_linked_list_node::previous.

Referenced by RemoveFromActiveConnections().

Here is the call graph for this function:

Here is the caller graph for this function: