Crossings Minimization  1.0
order.h
Go to the documentation of this file.
1 /**
2  * @file order.h
3  * @brief data structure and function headers for saving/restoring order
4  * information.
5  * @author Matt Stallmann
6  * @date 2009/07/27
7  * $Id: order.h 2 2011-06-07 19:50:41Z mfms $
8  */
9 
10 #ifndef ORDER_H
11 #define ORDER_H
12 
13 #include"graph.h"
14 
15 /**
16  * Keeps track of order information for each layer; used to save the state
17  * for orderings that give minimum crossings or edge crossings.
18  */
19 typedef struct order_struct {
23 } * Orderptr;
24 
25 /**
26  * Allocates information inside the ord_info based on the current graph and
27  * saves current (initial) layer ordering
28  */
29 void init_order( Orderptr ord_info );
30 
31 /**
32  * Deallocates information.
33  * ASSUMES: init_order( ord_info ) was previously called
34  */
35 void cleanup_order( Orderptr ord_info );
36 
37 /**
38  * Copies information from the current graph configuration into the
39  * order_struct referenced by ord_info.
40  */
41 void save_order( Orderptr ord_info );
42 
43 /**
44  * Reaaranges layers of the graph to match the information stored in the
45  * order_struct referenced by ord_info.
46  */
47 void restore_order( Orderptr ord_info );
48 
49 #endif
50 
51 /* [Last modified: 2011 05 23 at 16:11:40 GMT] */
void restore_order(Orderptr ord_info)
Definition: order.c:61
int * num_nodes_on_layer
Definition: order.h:21
void cleanup_order(Orderptr ord_info)
Definition: order.c:37
Nodeptr ** node_ptr_on_layer
Definition: order.h:22
struct order_struct * Orderptr
Definition of data structures and access functions for a layered graph.
void init_order(Orderptr ord_info)
Definition: order.c:21
void save_order(Orderptr ord_info)
Definition: order.c:48
int num_layers
Definition: order.h:20