obdeque Private Interace
More...
Go to the source code of this file.
|
struct | obdeque_node_struct |
| obdeque_node internal structure, encapsulating the data needed for an node within a doubly linked list. Internally referenced only More...
|
|
struct | obdeque_iterator_struct |
| obdeque_nodeIterator internal structure, encapsulating the data needed for an iterator of a doubly linked list. More...
|
|
struct | obdeque_struct |
| obdeque internal structure, encapsulating the data needed for a doubly linked list More...
|
|
|
typedef struct obdeque_node_struct | obdeque_node |
| obdeque_node internal structure, encapsulating the data needed for an node within a doubly linked list. Internally referenced only
|
|
obdeque Private Interace
- Author
- theck
int8_t obdeque_compare |
( |
const obj * |
a, |
|
|
const obj * |
b |
|
) |
| |
Compares two instances of obdeque.
- Parameters
-
a | A non-NULL obj pointer to type obdeque |
b | A non-NULL obj pointer to type obdeque |
- Return values
-
OB_LESS_THAN | obj a is less than b |
OB_GREATER_THAN | obj a is equivalent to b |
OB_EQUAL_TO | obj a is greater than b |
obdeque* obdeque_create_default |
( |
void |
) | |
|
Default constructor for obdeque.
- Returns
- An instance of class obdeque
- Warning
- All public constructors should call this constructor and initialize individual members as needed, so that all base data is initialized properly
void obdeque_destroy |
( |
obj * |
to_dealloc) | |
|
Destructor for obdeque.
- Parameters
-
to_dealloc | An obj pointer to an instance of obdeque with reference count 0 |
- Warning
- Do not call manually, release will call automatically when the instances reference count drops to 0!
void obdeque_destroy_iterator |
( |
obj * |
to_dealloc) | |
|
Destructor for obdeque_iterator.
- Parameters
-
to_dealloc | An obj pointer to an instance of obdeque_iterator with reference count 0 |
- Warning
- Do not call manually, release will call automatically when the instances reference count drops to 0!
void obdeque_destroy_node |
( |
obj * |
to_dealloc) | |
|
Destructor for obdeque_node.
- Parameters
-
to_dealloc | An obj pointer to an instance of obdeque_node with reference count 0 |
- Warning
- Do not call manually, release will call automatically when the instances reference count drops to 0!
void obdeque_display |
( |
const obj * |
to_print) | |
|
Displays information about an obdeque to stderr.
- Parameters
-
to_print | A non-NULL obj pointer to type obdeque |
Hash function for obdeque.
- Parameters
-
to_hash | An obj pointer to an instance of obdeque |
- Returns
- Key value (hash) for the given obj pointer to a obdeque
Constructor, creates an instance of obdeque_iterator bound to an obdeque and an obdeque_node within that deque.
- Parameters
-
deque | An instance of obdeque |
node | An instance of obdeque_node contained within deque |
- Returns
- An instance of obdeque_iterator
Constructor, creates a new obdeque_node containing an obj.
- Parameters
-
to_store | A non-NULL instance of any Offbrand compatible class |
- Returns
- A new instance of obdeque node storing to_store and with NULL references to next and prev nodes
Internal merge sort implementation for an obdeque.
- Parameters
-
deque | Static obdeque to be sorted |
order | Accepts OB_LEAST_TO_GREATEST or OB_GREATEST_TO_LEAST as valid sorting orders |
funct | A compare_fptr to a function that returns an int8_t when given two obj * arguments |
- Returns
- A sorted static deque
- Warning
- There is little to no parameter checking in this function, all sorting should use the publicly accessable function which calls this method internally.