alist.h File Reference


Detailed Description

List type used by automaton.

Author:
Antoine Fraboulet
Date:
2005

Definition in file alist.h.

Go to the source code of this file.

Typedefs

typedef alist_elt_talist_elt
 untyped list type element
typedef alist_talist
 untyped list type

Functions

void * alist_elt_get_value (alist_elt)
 extract the value from an alist element result is untyped si the user should know what the value type is
alist alist_create ()
 list creation
alist alist_clone (alist)
void alist_set_delete (alist, void(*f)(void *))
 funtion to use on data during list deletion.
void alist_delete (alist)
 delete a complete list.
void alist_add (alist, void *)
 add a element to the list
void alist_insert (alist, alist)
int alist_is_in (alist l, void *e)
 get first element
int alist_equal (alist, alist)
alist_elt alist_get_first (alist)
alist_elt alist_get_next (alist, alist_elt)
 get next element from current
int alist_is_empty (alist)
int alist_get_size (alist)
void * alist_pop_first_value (alist)


Typedef Documentation

typedef struct alist_t* alist
 

untyped list type

Definition at line 49 of file alist.h.

typedef struct alist_elt_t* alist_elt
 

untyped list type element

Definition at line 37 of file alist.h.


Function Documentation

void alist_add alist  ,
void * 
 

add a element to the list

Definition at line 114 of file alist.c.

References alist_elt_create(), alist_elt_t::next, alist_t::size, and alist_t::start.

Referenced by alist_clone(), alist_insert(), s_automaton_add_state(), s_automaton_id_create(), s_automaton_NFA_to_DFA(), and s_automaton_PS_to_NFA().

alist alist_clone alist   ) 
 

Definition at line 75 of file alist.c.

References alist_add(), alist_create(), alist_elt_get_value(), alist_get_first(), and alist_get_next().

Referenced by s_automaton_NFA_to_DFA().

alist alist_create  ) 
 

list creation

Returns:
list

Definition at line 64 of file alist.c.

References alist_t::delete_function, alist_t::size, and alist_t::start.

Referenced by alist_clone(), s_automaton_create(), s_automaton_id_create(), s_automaton_NFA_to_DFA(), s_automaton_PS_to_NFA(), and s_automaton_successor().

void alist_delete alist   ) 
 

delete a complete list.

Definition at line 107 of file alist.c.

References alist_delete_rec(), alist_t::delete_function, and alist_t::start.

Referenced by s_automaton_delete(), s_automaton_NFA_to_DFA(), s_automaton_PS_to_NFA(), s_automaton_successor(), and state_delete_fun().

void* alist_elt_get_value alist_elt   ) 
 

extract the value from an alist element result is untyped si the user should know what the value type is

Definition at line 44 of file alist.c.

References alist_elt_t::info.

Referenced by alist_clone(), alist_equal(), alist_insert(), alist_is_in(), s_automaton_get_state(), s_automaton_id_to_str(), s_automaton_node_set_accept(), s_automaton_print_edges(), s_automaton_print_nodes(), s_automaton_PS_to_NFA(), and s_automaton_successor().

int alist_equal alist  ,
alist 
 

Definition at line 134 of file alist.c.

References alist_elt_get_value(), alist_get_first(), alist_get_next(), alist_get_size(), and alist_is_in().

Referenced by s_automaton_get_state().

alist_elt alist_get_first alist   ) 
 

Definition at line 163 of file alist.c.

References alist_t::start.

Referenced by alist_clone(), alist_equal(), alist_insert(), alist_is_in(), s_automaton_get_state(), s_automaton_id_to_str(), s_automaton_node_set_accept(), s_automaton_print_edges(), s_automaton_print_nodes(), s_automaton_PS_to_NFA(), and s_automaton_successor().

alist_elt alist_get_next alist  ,
alist_elt 
 

get next element from current

Definition at line 169 of file alist.c.

References alist_elt_t::next.

Referenced by alist_clone(), alist_equal(), alist_insert(), alist_is_in(), s_automaton_get_state(), s_automaton_id_to_str(), s_automaton_node_set_accept(), s_automaton_print_edges(), s_automaton_print_nodes(), and s_automaton_successor().

int alist_get_size alist   ) 
 

Definition at line 191 of file alist.c.

References alist_t::size.

Referenced by alist_equal().

void alist_insert alist  ,
alist 
 

Definition at line 151 of file alist.c.

References alist_add(), alist_elt_get_value(), alist_get_first(), alist_get_next(), and alist_is_in().

Referenced by s_automaton_successor().

int alist_is_empty alist   ) 
 

Returns:
0 or 1

Definition at line 197 of file alist.c.

References alist_t::size.

Referenced by s_automaton_NFA_to_DFA(), s_automaton_PS_to_NFA(), and s_automaton_successor().

int alist_is_in alist  l,
void *  e
 

get first element

Definition at line 124 of file alist.c.

References alist_elt_get_value(), alist_get_first(), and alist_get_next().

Referenced by alist_equal(), alist_insert(), and s_automaton_node_set_accept().

void* alist_pop_first_value alist   ) 
 

Definition at line 175 of file alist.c.

References alist_delete_rec(), alist_t::delete_function, alist_elt_t::info, alist_elt_t::next, alist_t::size, and alist_t::start.

Referenced by s_automaton_NFA_to_DFA(), and s_automaton_PS_to_NFA().

void alist_set_delete alist  ,
void(*)(void *)  f
 

funtion to use on data during list deletion.

Definition at line 88 of file alist.c.

References alist_t::delete_function.

Referenced by s_automaton_create().


Generated on Thu Dec 29 02:01:15 2005 for Eliot by  doxygen 1.4.5