#include <gdtlist.h>
Public Types | |
typedef void * | item |
Public Member Functions | |
gdtlist () | |
gdtlist (const gdtlist< E > &l) | |
~gdtlist () | |
gdtlist< E > & | operator= (const gdtlist< E > &l) |
bool | operator== (const gdtlist< E > &l2) const |
Item * | first_item () const |
Item * | last_item () const |
Item * | next_item (gdt::list_item p) const |
Item * | pred_item (gdt::list_item p) const |
int | length () const |
int | size () const |
bool | empty () const |
gdt::list_item | first () const |
gdt::list_item | last () const |
gdt::list_item | get_item (int i) const |
gdt::list_item | succ (gdt::list_item li) const |
gdt::list_item | pred (gdt::list_item li) const |
gdt::list_item | cyclic_succ (gdt::list_item li) const |
gdt::list_item | cyclic_pred (gdt::list_item li) const |
const E & | contents (gdt::list_item li) const |
const E & | inf (gdt::list_item it) const |
const E & | front () const |
const E & | head () const |
const E & | back () const |
const E & | tail () const |
int | rank (const E &x) const |
gdt::list_item | push (const E &x) |
gdt::list_item | push_front (const E &x) |
gdt::list_item | append (const E &x) |
gdt::list_item | push_back (const E &x) |
gdt::list_item | insert (const E &x, gdt::list_item _pos, int dir=AFTER) |
const E & | operator[] (list_item it) const |
E & | operator[] (list_item it) |
void | swap_items (gdt::list_item it1, gdt::list_item it2) |
const E & | pop () |
const E & | pop_front () |
const E & | Pop () |
const E & | pop_back () |
const E & | del_item (gdt::list_item it) |
const E & | del (gdt::list_item it) |
void | erase (gdt::list_item it) |
void | remove (const E &x) |
void | assign (gdt::list_item li, const E &x) |
void | conc (gdtlist< E > &L1, int dir=AFTER) |
void | split (gdt::list_item _it, gdtlist< E > &L1, gdtlist< E > &L2) |
void | reverse_items () |
void | reverse () |
list_item | search (const E &x) const |
void | print (std::ostream &os, char space= ' ') const |
void | print (char space= ' ') const |
void | clear () |
bool | check_item (gdt::list_item lit) const |
bool | consistency_check () const |
Definition at line 43 of file gdtlist.h.
typedef void* gdt::gdtlist< E >::item |
gdt::gdtlist< E >::gdtlist | ( | ) | [inline] |
gdt::gdtlist< E >::gdtlist | ( | const gdtlist< E > & | l | ) | [inline] |
gdt::gdtlist< E >::~gdtlist | ( | ) | [inline] |
Definition at line 312 of file gdtlist.h.
References gdt::gdtlist< E >::clear().
Definition at line 320 of file gdtlist.h.
Referenced by gdt::gdtstack< E >::operator=(), and gdt::gdtqueue< PQ_node >::operator=().
bool gdt::gdtlist< E >::operator== | ( | const gdtlist< E > & | l2 | ) | const [inline] |
Definition at line 327 of file gdtlist.h.
References gdt::gdtlist< E >::first(), gdt::gdtlist< E >::inf(), and gdt::gdtlist< E >::succ().
gdtlist< E >::Item * gdt::gdtlist< E >::first_item | ( | ) | const [inline] |
gdtlist< E >::Item * gdt::gdtlist< E >::last_item | ( | ) | const [inline] |
gdtlist< E >::Item * gdt::gdtlist< E >::next_item | ( | gdt::list_item | p | ) | const [inline] |
Definition at line 352 of file gdtlist.h.
References NULL, and gdt::gdtlist< E >::succ().
Referenced by gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::next_item().
gdtlist< E >::Item * gdt::gdtlist< E >::pred_item | ( | gdt::list_item | p | ) | const [inline] |
Definition at line 354 of file gdtlist.h.
References NULL, and gdt::gdtlist< E >::pred().
Referenced by gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::pred_item().
int gdt::gdtlist< E >::length | ( | ) | const [inline] |
Definition at line 363 of file gdtlist.h.
Referenced by gdt::gdtstack< E >::size(), and gdt::gdtlist< E >::size().
int gdt::gdtlist< E >::size | ( | ) | const [inline] |
Reimplemented in gdt::gdtqueue< E >, gdt::gdtstack< E >, and gdt::gdtqueue< PQ_node >.
Definition at line 371 of file gdtlist.h.
References gdt::gdtlist< E >::length().
Referenced by gdt::PQ_tree< T >::bubble(), gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::consistency_check(), gdt::PQ_tree< T >::pnode_sorting(), gdt::PQ_tree< T >::reduce(), gdt::gdtqueue< PQ_node >::size(), gdt::PQ_tree< T >::template_P1(), gdt::PQ_tree< T >::template_P2(), gdt::PQ_tree< T >::template_P3(), gdt::PQ_tree< T >::template_P4(), gdt::PQ_tree< T >::template_P5(), gdt::PQ_tree< T >::template_P6(), gdt::PQ_tree< T >::template_Q1(), gdt::PQ_tree< T >::template_Q2(), and gdt::PQ_tree< T >::template_Q3().
bool gdt::gdtlist< E >::empty | ( | ) | const [inline] |
Reimplemented in gdt::gdtqueue< E >, gdt::gdtstack< E >, and gdt::gdtqueue< PQ_node >.
Definition at line 374 of file gdtlist.h.
References NULL.
Referenced by gdt::gdtlist< E >::clear(), gdt::gdtstack< E >::empty(), gdt::gdtqueue< PQ_node >::empty(), gdt::gdtlist< E >::insert(), and gdt::gdtlist< E >::print().
gdt::list_item gdt::gdtlist< E >::first | ( | ) | const [inline] |
Definition at line 377 of file gdtlist.h.
Referenced by gdt::gdtlist< E >::cyclic_pred(), gdt::gdtlist< E >::cyclic_succ(), gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::first_item(), gdt::gdtlist< E >::front(), gdt::gdtlist< E >::get_item(), gdt::gdtlist< E >::operator==(), gdt::gdtlist< E >::pop(), gdt::gdtlist< E >::print(), gdt::gdtlist< E >::push(), gdt::gdtlist< E >::rank(), gdt::gdtlist< E >::search(), and gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::show_list().
gdt::list_item gdt::gdtlist< E >::last | ( | ) | const [inline] |
Definition at line 382 of file gdtlist.h.
Referenced by gdt::gdtlist< E >::append(), gdt::gdtlist< E >::back(), gdt::gdtlist< E >::cyclic_pred(), gdt::gdtlist< E >::cyclic_succ(), gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::last_item(), gdt::gdtlist< E >::Pop(), and gdt::gdtlist< E >::print().
gdt::list_item gdt::gdtlist< E >::get_item | ( | int | i | ) | const [inline] |
Definition at line 385 of file gdtlist.h.
References gdt::gdtlist< E >::first(), and gdt::gdtlist< E >::succ().
gdt::list_item gdt::gdtlist< E >::succ | ( | gdt::list_item | li | ) | const [inline] |
Definition at line 398 of file gdtlist.h.
References gdt::Record< F >::succ.
Referenced by gdt::gdtlist< E >::cyclic_succ(), gdt::gdtlist< E >::get_item(), gdt::gdtlist< E >::next_item(), gdt::gdtlist< E >::operator==(), gdt::gdtlist< E >::print(), gdt::gdtlist< E >::rank(), gdt::gdtlist< E >::search(), and gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::show_list().
gdt::list_item gdt::gdtlist< E >::pred | ( | gdt::list_item | li | ) | const [inline] |
Definition at line 405 of file gdtlist.h.
References gdt::Record< F >::pred.
Referenced by gdt::gdtlist< E >::cyclic_pred(), and gdt::gdtlist< E >::pred_item().
gdt::list_item gdt::gdtlist< E >::cyclic_succ | ( | gdt::list_item | li | ) | const [inline] |
Definition at line 412 of file gdtlist.h.
References gdt::gdtlist< E >::first(), gdt::gdtlist< E >::last(), and gdt::gdtlist< E >::succ().
gdt::list_item gdt::gdtlist< E >::cyclic_pred | ( | gdt::list_item | li | ) | const [inline] |
Definition at line 418 of file gdtlist.h.
References gdt::gdtlist< E >::first(), gdt::gdtlist< E >::last(), and gdt::gdtlist< E >::pred().
const E & gdt::gdtlist< E >::contents | ( | gdt::list_item | li | ) | const [inline] |
Definition at line 424 of file gdtlist.h.
References gdt::Record< F >::inf.
Referenced by gdt::gdtlist< E >::back(), gdt::gdtlist< E >::front(), gdt::gdtlist< E >::inf(), gdt::gdtlist< E >::operator[](), and gdt::gdtlist< E >::rank().
const E & gdt::gdtlist< E >::inf | ( | gdt::list_item | it | ) | const [inline] |
Definition at line 434 of file gdtlist.h.
References gdt::gdtlist< E >::contents().
Referenced by gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::consistent_list(), gdt::gdtlist< E >::operator==(), gdt::gdtlist< E >::print(), gdt::gdtlist< E >::remove(), gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::remove(), and gdt::gdtlist< E >::search().
const E & gdt::gdtlist< E >::front | ( | ) | const [inline] |
Definition at line 440 of file gdtlist.h.
References gdt::gdtlist< E >::contents(), and gdt::gdtlist< E >::first().
Referenced by gdt::gdtlist< E >::head().
const E & gdt::gdtlist< E >::head | ( | ) | const [inline] |
Definition at line 446 of file gdtlist.h.
References gdt::gdtlist< E >::front().
Referenced by gdt::PQ_tree< T >::pnode_sorting(), gdt::PQ_tree< T >::template_P2(), gdt::PQ_tree< T >::template_P3(), gdt::PQ_tree< T >::template_P4(), gdt::PQ_tree< T >::template_P5(), gdt::PQ_tree< T >::template_P6(), gdt::PQ_tree< T >::template_Q3(), gdt::gdtstack< E >::top(), and gdt::gdtqueue< PQ_node >::top().
const E & gdt::gdtlist< E >::back | ( | ) | const [inline] |
Definition at line 449 of file gdtlist.h.
References gdt::gdtlist< E >::contents(), and gdt::gdtlist< E >::last().
Referenced by gdt::gdtlist< E >::print(), and gdt::gdtlist< E >::tail().
const E & gdt::gdtlist< E >::tail | ( | ) | const [inline] |
Definition at line 455 of file gdtlist.h.
References gdt::gdtlist< E >::back().
Referenced by gdt::PQ_tree< T >::bubble(), gdt::PQ_tree< T >::pnode_sorting(), gdt::PQ_tree< T >::reduce(), gdt::PQ_tree< T >::template_P2(), gdt::PQ_tree< T >::template_P3(), gdt::PQ_tree< T >::template_P4(), gdt::PQ_tree< T >::template_P6(), and gdt::PQ_tree< T >::template_Q3().
int gdt::gdtlist< E >::rank | ( | const E & | x | ) | const [inline] |
Definition at line 463 of file gdtlist.h.
References gdt::gdtlist< E >::contents(), gdt::gdtlist< E >::first(), NULL, and gdt::gdtlist< E >::succ().
gdt::list_item gdt::gdtlist< E >::push | ( | const E & | x | ) | [inline] |
Reimplemented in gdt::gdtstack< E >.
Definition at line 482 of file gdtlist.h.
References gdt::before, gdt::gdtlist< E >::first(), and gdt::gdtlist< E >::insert().
Referenced by gdt::gdtstack< E >::push(), and gdt::gdtlist< E >::push_front().
gdt::list_item gdt::gdtlist< E >::push_front | ( | const E & | x | ) | [inline] |
Definition at line 485 of file gdtlist.h.
References gdt::gdtlist< E >::push().
gdt::list_item gdt::gdtlist< E >::append | ( | const E & | x | ) | [inline] |
Reimplemented in gdt::gdtqueue< E >, and gdt::gdtqueue< PQ_node >.
Definition at line 488 of file gdtlist.h.
References gdt::after, gdt::gdtlist< E >::insert(), and gdt::gdtlist< E >::last().
Referenced by gdt::gdtqueue< PQ_node >::append(), gdt::PQ_tree< T >::assign_parent_to_draw_graph(), gdt::PQ_tree< T >::bubble(), gdt::gdtnode_pq< P >::get_nodes(), gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::insert(), gdt::PQ_tree< T >::operator=(), gdt::gdtlist< E >::push_back(), gdt::PQ_tree< T >::template_L1(), gdt::PQ_tree< T >::template_P1(), gdt::PQ_tree< T >::template_P2(), gdt::PQ_tree< T >::template_P3(), gdt::PQ_tree< T >::template_P4(), gdt::PQ_tree< T >::template_P5(), gdt::PQ_tree< T >::template_P6(), gdt::PQ_tree< T >::template_Q1(), gdt::PQ_tree< T >::template_Q2(), gdt::PQ_tree< T >::template_Q3(), gdt::PQ_tree_freezed< T >::tree_frontier(), and gdt::PQ_tree_freezed< T >::tree_search().
gdt::list_item gdt::gdtlist< E >::push_back | ( | const E & | x | ) | [inline] |
Definition at line 491 of file gdtlist.h.
References gdt::gdtlist< E >::append().
gdt::list_item gdt::gdtlist< E >::insert | ( | const E & | x, | |
gdt::list_item | _pos, | |||
int | dir = AFTER | |||
) | [inline] |
Definition at line 494 of file gdtlist.h.
References gdt::after, gdt::gdtlist< E >::empty(), gdt::Record< F >::inf, NULL, gdt::Record< F >::pred, and gdt::Record< F >::succ.
Referenced by gdt::gdtlist< E >::append(), and gdt::gdtlist< E >::push().
const E & gdt::gdtlist< E >::operator[] | ( | list_item | it | ) | const [inline] |
Definition at line 537 of file gdtlist.h.
References gdt::gdtlist< E >::contents().
E & gdt::gdtlist< E >::operator[] | ( | list_item | it | ) | [inline] |
void gdt::gdtlist< E >::swap_items | ( | gdt::list_item | it1, | |
gdt::list_item | it2 | |||
) | [inline] |
Definition at line 551 of file gdtlist.h.
References NULL, gdt::Record< F >::pred, and gdt::Record< F >::succ.
const E & gdt::gdtlist< E >::pop | ( | ) | [inline] |
Reimplemented in gdt::gdtqueue< E >, gdt::gdtstack< E >, and gdt::gdtqueue< PQ_node >.
Definition at line 609 of file gdtlist.h.
References gdt::gdtlist< E >::del_item(), and gdt::gdtlist< E >::first().
Referenced by gdt::gdtlist< E >::clear(), gdt::gdtstack< E >::pop(), gdt::gdtqueue< PQ_node >::pop(), gdt::gdtlist< E >::pop_front(), gdt::PQ_tree< T >::template_P6(), and gdt::PQ_tree< T >::template_Q2().
const E & gdt::gdtlist< E >::pop_front | ( | ) | [inline] |
Definition at line 612 of file gdtlist.h.
References gdt::gdtlist< E >::pop().
const E & gdt::gdtlist< E >::Pop | ( | ) | [inline] |
Definition at line 615 of file gdtlist.h.
References gdt::gdtlist< E >::del_item(), and gdt::gdtlist< E >::last().
Referenced by gdt::gdtlist< E >::pop_back().
const E & gdt::gdtlist< E >::pop_back | ( | ) | [inline] |
Definition at line 618 of file gdtlist.h.
References gdt::gdtlist< E >::Pop().
const E & gdt::gdtlist< E >::del_item | ( | gdt::list_item | it | ) | [inline] |
Definition at line 621 of file gdtlist.h.
References gdt::Record< F >::inf, gdt::Record< F >::pred, and gdt::Record< F >::succ.
Referenced by gdt::gdtlist< E >::del(), gdt::gdtlist< E >::erase(), gdt::gdtlist< E >::Pop(), gdt::gdtlist< E >::pop(), and gdt::gdtlist< E >::remove().
const E & gdt::gdtlist< E >::del | ( | gdt::list_item | it | ) | [inline] |
Definition at line 638 of file gdtlist.h.
References gdt::gdtlist< E >::del_item().
void gdt::gdtlist< E >::erase | ( | gdt::list_item | it | ) | [inline] |
Definition at line 641 of file gdtlist.h.
References gdt::gdtlist< E >::del_item().
Referenced by gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::extract_max(), and gdt::gdtbinary_heap2< P, struct_gdtnode, gdt::LessToGreater< P, gdt::stdless< P > > >::remove().
void gdt::gdtlist< E >::remove | ( | const E & | x | ) | [inline] |
Definition at line 644 of file gdtlist.h.
References gdt::gdtlist< E >::del_item(), gdt::gdtlist< E >::inf(), and gdt::Record< F >::succ.
void gdt::gdtlist< E >::assign | ( | gdt::list_item | li, | |
const E & | x | |||
) | [inline] |
void gdt::gdtlist< E >::conc | ( | gdtlist< E > & | L1, | |
int | dir = AFTER | |||
) | [inline] |
Definition at line 667 of file gdtlist.h.
References gdt::after, gdt::gdtlist< E >::counter, gdt::gdtlist< E >::firstitem, gdt::gdtlist< E >::lastitem, NULL, gdt::Record< F >::pred, gdt::Record< F >::succ, and UNKNOWN_COUNTER.
void gdt::gdtlist< E >::split | ( | gdt::list_item | _it, | |
gdtlist< E > & | L1, | |||
gdtlist< E > & | L2 | |||
) | [inline] |
Definition at line 705 of file gdtlist.h.
References gdt::gdtlist< E >::counter, gdt::gdtlist< E >::firstitem, gdt::gdtlist< E >::lastitem, NULL, gdt::Record< F >::pred, and UNKNOWN_COUNTER.
void gdt::gdtlist< E >::reverse_items | ( | ) | [inline] |
Definition at line 766 of file gdtlist.h.
References gdt::Record< F >::pred, gdt::Record< F >::succ, and gdt::Swap().
Referenced by gdt::gdtlist< E >::reverse().
void gdt::gdtlist< E >::reverse | ( | ) | [inline] |
Definition at line 778 of file gdtlist.h.
References gdt::gdtlist< E >::reverse_items().
list_item gdt::gdtlist< E >::search | ( | const E & | x | ) | const [inline] |
Definition at line 787 of file gdtlist.h.
References gdt::gdtlist< E >::first(), gdt::gdtlist< E >::inf(), and gdt::gdtlist< E >::succ().
void gdt::gdtlist< E >::print | ( | std::ostream & | os, | |
char | space = ' ' | |||
) | const [inline] |
Definition at line 801 of file gdtlist.h.
References gdt::gdtlist< E >::back(), gdt::gdtlist< E >::empty(), gdt::gdtlist< E >::first(), gdt::gdtlist< E >::inf(), gdt::gdtlist< E >::last(), and gdt::gdtlist< E >::succ().
Referenced by gdt::gdtlist< E >::print().
void gdt::gdtlist< E >::print | ( | char | space = ' ' |
) | const [inline] |
Definition at line 816 of file gdtlist.h.
References gdt::gdtlist< E >::print().
void gdt::gdtlist< E >::clear | ( | ) | [inline] |
Reimplemented in gdt::gdtqueue< E >, gdt::gdtstack< E >, and gdt::gdtqueue< PQ_node >.
Definition at line 823 of file gdtlist.h.
References gdt::gdtlist< E >::empty(), and gdt::gdtlist< E >::pop().
Referenced by gdt::PQ_tree< T >::bubble(), gdt::gdtstack< E >::clear(), gdt::gdtqueue< PQ_node >::clear(), gdt::gdtnode_pq< P >::get_nodes(), gdt::PQ_tree< T >::reduce(), gdt::PQ_tree< T >::template_P2(), gdt::PQ_tree< T >::template_P3(), gdt::PQ_tree< T >::template_P4(), gdt::PQ_tree< T >::template_P6(), gdt::PQ_tree< T >::template_Q3(), and gdt::gdtlist< E >::~gdtlist().
bool gdt::gdtlist< E >::check_item | ( | gdt::list_item | lit | ) | const [inline] |
bool gdt::gdtlist< E >::consistency_check | ( | ) | const [inline] |
Definition at line 833 of file gdtlist.h.
References NULL, gdt::Record< F >::pred, gdt::Record< F >::succ, and UNKNOWN_COUNTER.