Graphviz  2.41.20170921.2350
nodelist.h
Go to the documentation of this file.
1 /* $Id$ $Revision$ */
2 /* vim:set shiftwidth=4 ts=8: */
3 
4 /*************************************************************************
5  * Copyright (c) 2011 AT&T Intellectual Property
6  * All rights reserved. This program and the accompanying materials
7  * are made available under the terms of the Eclipse Public License v1.0
8  * which accompanies this distribution, and is available at
9  * http://www.eclipse.org/legal/epl-v10.html
10  *
11  * Contributors: See CVS logs. Details at http://www.graphviz.org/
12  *************************************************************************/
13 
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17 
18 #ifndef NODELIST_H
19 #define NODELIST_H
20 
21 #include <render.h>
22 
23  typedef struct nodelistitem nodelistitem_t;
24 
25  struct nodelistitem {
29  };
30 
31  typedef struct {
34  int sz;
35  } nodelist_t;
36 
37  extern nodelist_t *mkNodelist(void);
38  extern void freeNodelist(nodelist_t *);
39  extern int sizeNodelist(nodelist_t * list);
40 
41  extern void appendNodelist(nodelist_t *, nodelistitem_t *,
42  Agnode_t * n);
43 /* extern void removeNodelist(nodelist_t* list, Agnode_t* n); */
44 /* extern int node_exists(nodelist_t* list, Agnode_t* n); */
45 /* extern int nodename_exists(nodelist_t* list, char* n); */
46  extern int node_position(nodelist_t * list, Agnode_t * n);
47 
48  extern void realignNodelist(nodelist_t * list, nodelistitem_t * n);
49  extern void insertNodelist(nodelist_t *, Agnode_t *, Agnode_t *, int);
50 
51  extern void reverseAppend(nodelist_t *, nodelist_t *);
52  extern nodelist_t *reverseNodelist(nodelist_t * list);
53  extern nodelist_t *cloneNodelist(nodelist_t * list);
54 
55 #ifdef DEBUG
56  extern void printNodelist(nodelist_t * list);
57 #endif
58 
59 #endif
60 
61 #ifdef __cplusplus
62 }
63 #endif
nodelistitem_t * last
Definition: nodelist.h:33
void insertNodelist(nodelist_t *list, Agnode_t *cn, Agnode_t *neighbor, int pos)
Definition: nodelist.c:192
int sz
Definition: nodelist.h:34
void realignNodelist(nodelist_t *list, nodelistitem_t *np)
Definition: nodelist.c:152
nodelist_t * cloneNodelist(nodelist_t *list)
Definition: nodelist.c:174
nodelist_t * mkNodelist()
Definition: nodelist.c:26
nodelistitem_t * prev
Definition: nodelist.h:28
void reverseAppend(nodelist_t *l1, nodelist_t *l2)
Definition: nodelist.c:349
int sizeNodelist(nodelist_t *list)
Definition: nodelist.c:255
nodelistitem_t * first
Definition: nodelist.h:32
int node_position(nodelist_t *list, Agnode_t *n)
Definition: nodelist.c:310
void freeNodelist(nodelist_t *list)
Definition: nodelist.c:32
void appendNodelist(nodelist_t *list, nodelistitem_t *one, Agnode_t *n)
Definition: nodelist.c:51
node_t * curr
Definition: nodelist.h:26
nodelist_t * reverseNodelist(nodelist_t *list)
Definition: nodelist.c:131
nodelistitem_t * next
Definition: nodelist.h:27