|
Graphviz 14.1.0~dev.20251129.2323
|
count graph components More...
#include <stdbool.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include <cgraph/cgraph.h>#include <cgraph/cghdr.h>#include <cgraph/ingraphs.h>#include <common/render.h>#include <common/utils.h>#include <util/exit.h>#include <util/list.h>#include <getopt.h>Go to the source code of this file.
Data Structures | |
| struct | nodeinfo_t |
Macros | |
| #define | ND_dfs_mark(n) (((nodeinfo_t*)(n->base.data))->dfs_mark) |
| #define | NODES 1 |
| #define | EDGES 2 |
| #define | CC 4 |
| #define | CL 8 |
| #define | DIRECTED 1 |
| #define | UNDIRECTED 2 |
| #define | GTYPE(g) (agisdirected(g)?DIRECTED:UNDIRECTED) |
Functions | |
| static void | usage (int v) |
| static void | init (int argc, char *argv[]) |
| static | LIST (Agnode_t *) |
| static Agnode_t * | pop (void) |
| static void | cc_dfs (Agraph_t *g, Agnode_t *n) |
| static void | cntCluster (Agraph_t *g, Agobj_t *sg, void *arg) |
| static int | cc_decompose (Agraph_t *g) |
| static void | ipr (long num) |
| static void | wcp (int nnodes, int nedges, int ncc, int ncl, char *gname, char *filename) |
| static void | emit (Agraph_t *g, int root, int cl_count) |
| static int | eval (Agraph_t *g, int root) |
| int | main (int argc, char *argv[]) |
Variables | |
| static int | tot_edges |
| static int | tot_nodes |
| static int | tot_cc |
| static int | tot_cl |
| static int | n_graphs |
| static int | n_indent |
| static int | recurse |
| static int | silent |
| static int | verbose |
| static int | gtype |
| static int | flags |
| static char * | fname |
| static char ** | Inputs |
| static FILE * | outfile |
| static char * | useString |
| #define GTYPE | ( | g | ) | (agisdirected(g)?DIRECTED:UNDIRECTED) |
| #define ND_dfs_mark | ( | n | ) | (((nodeinfo_t*)(n->base.data))->dfs_mark) |
|
static |
Definition at line 194 of file gc.c.
References agfstnode(), agnxtnode(), cc_dfs(), and ND_dfs_mark.
Referenced by emit().
Definition at line 167 of file gc.c.
References agfstedge(), aghead, agnxtedge(), agtail, ND_dfs_mark, pop(), and push().
Referenced by cc_decompose().
|
static |
Definition at line 240 of file gc.c.
References agnameof(), agnedges(), agnnodes(), CC, cc_decompose(), CL, flags, fname, n_graphs, tot_cc, tot_cl, tot_edges, tot_nodes, and wcp().
Referenced by eval().
|
static |
Definition at line 269 of file gc.c.
References agapply(), agfstsubg(), aginit(), AGNODE, agnxtsubg(), CL, cntCluster(), emit(), eval(), flags, gtype, GTYPE, n_indent, and recurse.
Referenced by eval(), main(), usage(), usage(), usage(), usage(), and usage().
|
static |
|
static |
|
static |
Definition at line 151 of file gc.c.
References LIST_PUSH_BACK, and ND_dfs_mark.
| int main | ( | int | argc, |
| char * | argv[] | ||
| ) |
Definition at line 295 of file gc.c.
References agclose(), agnameof(), eval(), fileName(), fname, graphviz_exit(), init(), Inputs, LIST_FREE, n_graphs, newIngraph(), nextGraph(), NULL, prev, tot_cc, tot_cl, tot_edges, tot_nodes, verbose, and wcp().
|
static |
Definition at line 159 of file gc.c.
References LIST_IS_EMPTY, and LIST_POP_BACK.
Referenced by cc_dfs().
|
static |
Definition at line 81 of file gc.c.
References graphviz_exit(), and useString.
|
static |
|
static |
Definition at line 61 of file gc.c.
Referenced by compileProg(), doFlags(), EmbedText(), emit(), emit_begin_edge(), emit_begin_node(), emit_clusters(), emit_edge_label(), emit_graph(), emit_map_rect(), emit_page(), emit_view(), errorv(), estimate_textspan_size(), eval(), exsub(), get_gradient_points(), grpmatch(), gv_fopen(), gv_xml_escape(), gvputs_xml(), init(), initMapData(), map_label(), map_point(), onematch(), pango_textlayout(), parseStyle(), sfprint(), sfvscanf(), strgrpmatch(), svg_begin_anchor(), svg_textspan(), wcp(), xdot_textspan(), xml_core(), xml_puts(), xml_puts(), xml_url_puts(), and xml_url_puts().
|
static |
Definition at line 66 of file gc.c.
Referenced by usage().