Graphviz 13.0.0~dev.20241212.1010
|
parent for graphs, nodes, and edges. More...
Modules | |
nodes | |
graphs | |
edges | |
Files | |
file | obj.c |
generic manipulations with Agobj_t and derived objects graphs, nodes and edges | |
Data Structures | |
struct | Agtag_s |
tag in Agobj_s for graphs, nodes, and edges. More... | |
struct | Agobj_s |
a generic header of Agraph_s, Agnode_s and Agedge_s More... | |
Macros | |
#define | AGTAG(obj) (((Agobj_t *)(obj))->tag) |
#define | AGTYPE(obj) (AGTAG(obj).objtype) |
returns AGRAPH, AGNODE, or AGEDGE depending on the type of the object | |
#define | AGID(obj) (AGTAG(obj).id) |
returns the unique integer ID associated with the object | |
#define | AGSEQ(obj) (AGTAG(obj).seq) |
#define | AGATTRWF(obj) (AGTAG(obj).attrwf) |
#define | AGDATA(obj) (((Agobj_t *)(obj))->data) |
returns Agrec_t | |
Typedefs | |
typedef uint64_t | IDTYPE |
unique per main graph ID | |
typedef struct Agtag_s | Agtag_t |
typedef struct Agobj_s | Agobj_t |
generic object header | |
Enumerations | |
enum | { AGRAPH , AGNODE , AGEDGE , AGOUTEDGE = AGEDGE , AGINEDGE } |
Object tags. Can't exceed 2 bits. See Agtag_s. More... | |
Functions | |
Agraph_t * | agraphof (void *obj) |
Agraph_t * | agroot (void *obj) |
int | agcontains (Agraph_t *, void *obj) |
returns non-zero if obj is a member of (sub)graph | |
char * | agnameof (void *) |
returns a string descriptor for the object. | |
int | agdelete (Agraph_t *g, void *obj) |
deletes object. Equivalent to agclose, agdelnode, and agdeledge for obj being a graph, node or edge, respectively. | |
int | agobjkind (void *obj) |
Common parameter for functions obj is generic pointer to Agraph_t, Agnode_t, or Agedge_t
AGDATA, AGID, AGTYPE, and others are macros returning the specified fields of the argument object.
anonymous enum |
int agcontains | ( | Agraph_t * | g, |
void * | obj | ||
) |
Definition at line 234 of file obj.c.
References AGID, agidnode(), AGNODE, agparent(), AGRAPH, agroot(), agsubedge(), and AGTYPE.
Referenced by checkCompound(), flat_search(), getval(), interclexp(), is_a_normal_node_of(), is_a_vnode_of_an_edge_of(), node_induce(), rebuild_vlists(), twopi_layout(), vnode_not_related_to(), write_edge_test(), and write_node_test().
int agdelete | ( | Agraph_t * | g, |
void * | obj | ||
) |
Definition at line 19 of file obj.c.
References agclose(), agdeledge(), agdelnode(), agerrorf(), AGINEDGE, AGNODE, AGOUTEDGE, agparent(), AGRAPH, AGTYPE, FAILURE, and SUCCESS.
Referenced by cccomps(), deleteEdge(), deleteNode(), deleteObj(), dfs(), dfs(), dfs(), doDot(), find_pair_edges(), gvpr_core(), layout(), main(), mark_clusters(), neato_layout(), node_induce(), process(), processClusterEdges(), processClusters(), prune(), remove_pair_edges(), reverse_edge2(), rm(), rm(), scan_graph_mode(), sfdp_layout(), twopi_layout(), and undoClusterEdges().
char * agnameof | ( | void * | obj | ) |
Return string representation of object. In general, returns the name of node or graph, and the key of an edge. If edge is anonymous, returns NULL. Uses static buffer for anonymous graphs.
Definition at line 158 of file id.c.
References AGCLOS, AGDISC, AGEDGE, AGID, aginternalmapprint(), agraphof(), AGTYPE, LOCALNAMEPREFIX, NULL, and print().
Referenced by addCutPts(), addGrid(), addRevEdge(), attachOrthoEdges(), bundle(), cccomps(), checkCompound(), chkGraphName(), chkPos(), circleLayout(), circomps(), clarify(), cleanup2(), clone_graph(), cloneG(), cloneGraph(), cloneGraph(), cloneNode(), cloneO(), cloneSubg(), cloneSubg(), clustNode(), compile_nodes(), compile_samerank(), contain_nodes(), copy(), deleteObj(), deriveClusters(), deriveGraph(), deriveGraph(), dfs(), dfs(), dfs(), do_ordering_for_nodes(), edgecmd_internal(), emit(), emit_clusters(), emit_edge(), emit_node(), emitNode(), emitNodeAttrs(), epsf_init(), fdp_initParams(), fig_begin_graph(), fillMap(), find_blocks(), findCComp(), finishEdge(), genPoly(), genroute(), getsplinepoints(), graphcmd_internal(), graphviz_tred(), gvToolTred(), htmlEntityUTF8(), Import_coord_clusters_from_dot(), init_graph(), init_gvc(), init_nop(), init_params(), init_rank(), init_xdot(), initialPositions(), install_in_rank(), is_a_cluster(), is_anonymous(), IS_CLUSTER(), iterateBody(), iterateHdr(), kkNeato(), label_subgs(), labelOf(), lasi_begin_cluster(), lasi_begin_graph(), layout(), layout(), loadGraph(), lookup(), main(), main(), make_flat_adj_edges(), make_label(), makeCompoundEdge(), makePolyline(), makeSpline(), map_begin_page(), map_edge(), mapc(), mapN(), mark_clusters(), merge2(), mkBlock(), mkConstraintG(), mkNConstraintG(), move_node(), multicolor(), nameof(), nameof(), nameOf(), nameOf(), neatoMode(), neatoModel(), nodecmd_internal(), nodeID(), pic_begin_graph(), poly_gencode(), poly_init(), poly_port(), polyGraphs(), populate_data(), portName(), post(), pov_begin_graph(), pov_begin_node(), printSorted(), process(), process(), processClusters(), projectG(), psgen_begin_cluster(), psgen_begin_graph(), quartzgen_begin_page(), readGraphs(), rebuild_vlists(), record_port(), removeOverlapWith(), renderNodeLabels(), reposition(), rm(), rm(), routesplines_(), scan_graph_mode(), setEdgeLen(), setval(), solve_model(), SparseMatrix_import_dot(), strdup_and_subst_obj0(), strong(), svg_begin_cluster(), svg_begin_graph(), svg_begin_node(), svg_begin_page(), tkgen_begin_graph(), twopi_layout(), unrecognized(), user_pos(), user_spline(), walkTree(), write_edge_name(), write_graph(), write_hdr(), write_hdr(), write_node(), write_nodename(), write_plain(), writeEdgeName(), writeHdr(), writeNode(), and writenodeandport().
int agobjkind | ( | void * | obj | ) |
returns AGRAPH, AGNODE, or AGEDGE depending on the type of the object. Synonym for AGTYPE.
Definition at line 253 of file obj.c.
References AGTYPE.
Referenced by getObjId(), gvevent_enter_obj(), gvevent_leave_obj(), gvevent_select_current_obj(), kindOf(), make_html_label(), make_label(), nameOf(), parseXdotwithattrs(), pick_object_xyz(), setAttr(), and strdup_and_subst_obj0().
Agraph_t * agraphof | ( | void * | obj | ) |
Definition at line 184 of file obj.c.
References agerrorf(), AGINEDGE, AGNODE, AGOUTEDGE, AGRAPH, AGTYPE, NULL, and Agraph_s::root.
Referenced by agbindrec(), agcopyattr(), agdelrec(), agmakeattrs(), agnameof(), agrecclose(), agrelabel_node(), agrename(), agsafeset(), agxset(), arrow_flags(), beginpath(), clip_and_install(), cloneEdge(), closestSide(), clustNode(), common_init_edge(), common_init_node(), compassPoint(), compassPort(), copyAttr(), deleteObj(), dict_relabel(), dot_init_node(), edge(), edge(), edge(), edgecmd_internal(), emit_begin_edge(), emit_begin_node(), emit_edge(), emit_node(), endpath(), epsf_inside(), findedge(), firstattr(), firstattr(), firstedge(), firsthead(), firstin(), firstout(), firsttail(), freeattr(), genroute(), getv(), getv(), getval(), graphcmd_internal(), graphof(), graphof(), gv_edge_state(), gv_node_state(), gvevent_enter_obj(), init_node(), initGraphAttrs(), lookup(), make_html_label(), make_label(), makeGraph(), makeLineEdge(), makePortLabels(), makeSelfArcs(), mapN(), multicolor(), myagxset(), myagxset(), nameOf(), nameOf(), neato_init_node(), nextattr(), nextattr(), nextedge(), nexthead(), nextin(), nextout(), nexttail(), nodecmd_internal(), object_color(), place_vnlabel(), point_inside(), poly_init(), poly_inside(), record_init(), record_inside(), record_path(), rm(), rm(), routesplines_(), sameG(), sameport(), selfBottom(), selfLeft(), selfRight(), selfRightSpace(), selfTop(), setattr(), setv(), setv(), star_inside(), strdup_and_subst_obj0(), subedge_search(), subnode_search(), taperfun(), topdictsize(), visit(), walkTree(), write_edge(), write_edge_name(), write_node(), write_nodename(), write_nondefault_attrs(), write_plain(), write_port(), and writenodeandport().
Agraph_t * agroot | ( | void * | obj | ) |
takes any graph object (graph, subgraph, node, edge) and returns the root graph in which it lives
Definition at line 167 of file obj.c.
References agerrorf(), AGINEDGE, AGNODE, AGOUTEDGE, AGRAPH, AGTYPE, and NULL.
Referenced by addClusterObj(), addOutputGraph(), agcontains(), agdeledge(), agdelnode(), agdelrec(), agedge(), agidedge(), agidnode(), agmakeattrs(), agnode(), agnodebefore(), agopen1(), agrelabel_node(), agrename(), build_ranks(), circo_init_graph(), cloneAttrs(), cloneGraph(), clust_ht(), clustNode(), countClusterLabels(), deleteGraph(), deleteObj(), deriveGraph(), do_graph_label(), dot_cleanup_graph(), dot_init_subg(), dot_root(), edgecmd_internal(), fdp_init_graph(), firstattr(), getv(), getv(), getval(), graphcmd_internal(), graphof(), graphviz_node_induce(), gvLayoutJobs(), init_all_attrs(), initnode(), installnode(), irrelevant_subgraph(), isEdge(), label_subgs(), label_vnode(), lockGraph(), lookup(), make_label(), make_lrvn(), merge_ranks(), mkClusters(), neato_init_graph(), newnode(), nextattr(), nodecmd_internal(), nodeInduce(), place_flip_graph_label(), place_graph_label(), posOf(), preprocessTooltip(), rm(), rootof(), sameG(), setattr(), setattr(), setedgeattributes(), setgraphattributes(), setnodeattributes(), setv(), setv(), setv(), setval(), sfdp_init_graph(), strdup_and_subst_obj0(), topdictsize(), twopi_init_graph(), unviewsubgraphsattr(), virtual_node(), write_attrs(), x_layout(), and xinit_params().