apt_obj_list.h File Reference

List of Opaque void* Objects. More...

#include "apt.h"

Go to the source code of this file.

Typedefs

typedef
typedefAPT_BEGIN_EXTERN_C
struct apt_obj_list_t 
apt_obj_list_t
typedef struct apt_list_elem_t apt_list_elem_t

Functions

apt_obj_list_tapt_list_create (apr_pool_t *pool)
void apt_list_destroy (apt_obj_list_t *list)
apt_list_elem_tapt_list_push_back (apt_obj_list_t *list, void *obj, apr_pool_t *pool)
void * apt_list_pop_front (apt_obj_list_t *list)
void * apt_list_head (const apt_obj_list_t *list)
void * apt_obj_list_tail (const apt_obj_list_t *list)
apt_list_elem_tapt_list_first_elem_get (const apt_obj_list_t *list)
apt_list_elem_tapt_list_last_elem_get (const apt_obj_list_t *list)
apt_list_elem_tapt_list_next_elem_get (const apt_obj_list_t *list, apt_list_elem_t *elem)
apt_list_elem_tapt_list_prev_elem_get (const apt_obj_list_t *list, apt_list_elem_t *elem)
apt_list_elem_tapt_list_elem_insert (apt_obj_list_t *list, apt_list_elem_t *elem, void *obj, apr_pool_t *pool)
apt_list_elem_tapt_list_elem_remove (apt_obj_list_t *list, apt_list_elem_t *elem)
apt_bool_t apt_list_is_empty (const apt_obj_list_t *list)
void * apt_list_elem_object_get (const apt_list_elem_t *elem)

Detailed Description

List of Opaque void* Objects.


Typedef Documentation

Opaque list element declaration

typedef typedefAPT_BEGIN_EXTERN_C struct apt_obj_list_t apt_obj_list_t

Opaque list declaration


Function Documentation

apt_obj_list_t* apt_list_create ( apr_pool_t *  pool  ) 

Create list.

Parameters:
pool the pool to allocate list from
Returns:
the created list
void apt_list_destroy ( apt_obj_list_t list  ) 

Destroy list.

Parameters:
list the list to destroy
apt_list_elem_t* apt_list_elem_insert ( apt_obj_list_t list,
apt_list_elem_t elem,
void *  obj,
apr_pool_t *  pool 
)

Insert element to the list.

Parameters:
list the list to insert element to
elem the element to insert before
obj the object to insert
pool the pool to allocate list element from
Returns:
the inserted element
void* apt_list_elem_object_get ( const apt_list_elem_t elem  ) 

Retrieve the object associated with element.

Parameters:
elem the element to retrieve object from
apt_list_elem_t* apt_list_elem_remove ( apt_obj_list_t list,
apt_list_elem_t elem 
)

Remove element from the list.

Parameters:
list the list to remove element from
elem the element to remove
Returns:
the next element (if any)
apt_list_elem_t* apt_list_first_elem_get ( const apt_obj_list_t list  ) 

Retrieve the first element of the list.

Parameters:
list the list to retrieve from
void* apt_list_head ( const apt_obj_list_t list  ) 

Retrieve object of the first element in the list.

Parameters:
list the list to retrieve from
apt_bool_t apt_list_is_empty ( const apt_obj_list_t list  ) 

Query whether the list is empty.

Parameters:
list the list to query
Returns:
TRUE if empty, otherwise FALSE
apt_list_elem_t* apt_list_last_elem_get ( const apt_obj_list_t list  ) 

Retrieve the last element of the list.

Parameters:
list the list to retrieve from
apt_list_elem_t* apt_list_next_elem_get ( const apt_obj_list_t list,
apt_list_elem_t elem 
)

Retrieve the next element of the list.

Parameters:
list the list to retrieve from
elem the element to retrieve next element from
void* apt_list_pop_front ( apt_obj_list_t list  ) 

Pop object from the list as first in, first out.

Parameters:
list the list to pop message from
Returns:
the popped object (if any)
apt_list_elem_t* apt_list_prev_elem_get ( const apt_obj_list_t list,
apt_list_elem_t elem 
)

Retrieve the prev element of the list.

Parameters:
list the list to retrieve from
elem the element to retrieve prev element from
apt_list_elem_t* apt_list_push_back ( apt_obj_list_t list,
void *  obj,
apr_pool_t *  pool 
)

Push object to the list as first in, first out.

Parameters:
list the list to push object to
obj the object to push
pool the pool to allocate list element from
Returns:
the inserted element
void* apt_obj_list_tail ( const apt_obj_list_t list  ) 

Retrieve object of the last element in the list.

Parameters:
list the list to retrieve from
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Generated on 25 Mar 2013 for UniMRCP by  doxygen 1.6.1