Graphviz 12.0.1~dev.20240715.2254
Loading...
Searching...
No Matches
edge.c File Reference
#include <assert.h>
#include <cgraph/cghdr.h>
#include <cgraph/node_set.h>
#include <stddef.h>
#include <stdbool.h>
Include dependency graph for edge.c:

Go to the source code of this file.

Functions

Agedge_tagfstout (Agraph_t *g, Agnode_t *n)
 
Agedge_tagnxtout (Agraph_t *g, Agedge_t *e)
 
Agedge_tagfstin (Agraph_t *g, Agnode_t *n)
 
Agedge_tagnxtin (Agraph_t *g, Agedge_t *e)
 
Agedge_tagfstedge (Agraph_t *g, Agnode_t *n)
 
Agedge_tagnxtedge (Agraph_t *g, Agedge_t *e, Agnode_t *n)
 
static Agedge_tagfindedge_by_key (Agraph_t *g, Agnode_t *t, Agnode_t *h, Agtag_t key)
 
static Agedge_tagfindedge_by_id (Agraph_t *g, Agnode_t *t, Agnode_t *h, IDTYPE id)
 
Agsubnode_tagsubrep (Agraph_t *g, Agnode_t *n)
 
static void ins (Dict_t *d, Dtlink_t **set, Agedge_t *e)
 
static void del (Dict_t *d, Dtlink_t **set, Agedge_t *e)
 
static void installedge (Agraph_t *g, Agedge_t *e)
 
static void subedge (Agraph_t *g, Agedge_t *e)
 
static Agedge_tnewedge (Agraph_t *g, Agnode_t *t, Agnode_t *h, IDTYPE id)
 
static bool ok_to_make_edge (Agraph_t *g, Agnode_t *t, Agnode_t *h)
 
Agedge_tagidedge (Agraph_t *g, Agnode_t *t, Agnode_t *h, IDTYPE id, int cflag)
 
Agedge_tagedge (Agraph_t *g, Agnode_t *t, Agnode_t *h, char *name, int cflag)
 
void agdeledgeimage (Agraph_t *g, Agedge_t *e, void *ignored)
 
int agdeledge (Agraph_t *g, Agedge_t *e)
 
Agedge_tagsubedge (Agraph_t *g, Agedge_t *e, int cflag)
 
static int agedgeidcmpf (void *arg_e0, void *arg_e1)
 
static int agedgeseqcmpf (void *arg_e0, void *arg_e1)
 
int ageqedge (Agedge_t *e, Agedge_t *f)
 
Agedge_tagmkout (Agedge_t *e)
 
Agedge_tagmkin (Agedge_t *e)
 
Agnode_tagtail (Agedge_t *e)
 
Agnode_taghead (Agedge_t *e)
 
Agedge_tagopp (Agedge_t *e)
 

Variables

Dtdisc_t Ag_mainedge_seq_disc
 
Dtdisc_t Ag_subedge_seq_disc
 
Dtdisc_t Ag_mainedge_id_disc
 
Dtdisc_t Ag_subedge_id_disc
 

Function Documentation

◆ agdeledgeimage()

void agdeledgeimage ( Agraph_t g,
Agedge_t e,
void *  ignored 
)

Definition at line 304 of file edge.c.

References agfstin(), agfstout(), AGIN2OUT, AGINEDGE, agnxtin(), agnxtout(), AGOUT2IN, agsubrep(), AGTYPE, del(), Agraph_s::e_id, Agraph_s::e_seq, Agsubnode_s::in_id, Agsubnode_s::in_seq, Agedge_s::node, out(), Agsubnode_s::out_id, and Agsubnode_s::out_seq.

Referenced by agdeledge(), and agdelnodeimage().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ agedgeidcmpf()

static int agedgeidcmpf ( void *  arg_e0,
void *  arg_e1 
)
static

Definition at line 376 of file edge.c.

References AGID, AGTYPE, and Agedge_s::node.

◆ agedgeseqcmpf()

static int agedgeseqcmpf ( void *  arg_e0,
void *  arg_e1 
)
static

Definition at line 391 of file edge.c.

References AGSEQ, and Agedge_s::node.

◆ ageqedge()

int ageqedge ( Agedge_t e,
Agedge_t f 
)

Definition at line 435 of file edge.c.

References AGEQEDGE.

◆ agfindedge_by_id()

static Agedge_t * agfindedge_by_id ( Agraph_t g,
Agnode_t t,
Agnode_t h,
IDTYPE  id 
)
static

Definition at line 134 of file edge.c.

References AGEDGE, agfindedge_by_key(), id, Agtag_s::id, and Agtag_s::objtype.

Referenced by agidedge().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ agfindedge_by_key()

static Agedge_t * agfindedge_by_key ( Agraph_t g,
Agnode_t t,
Agnode_t h,
Agtag_t  key 
)
static

Definition at line 114 of file edge.c.

References agsubrep(), dtextract(), dtrestore(), dtsearch, Agraph_s::e_id, Agsubnode_s::in_id, key, and NULL.

Referenced by agdeledge(), agedge(), agfindedge_by_id(), agsubedge(), installedge(), and ok_to_make_edge().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ aghead()

Agnode_t * aghead ( Agedge_t e)

Definition at line 471 of file edge.c.

References AGHEAD.

◆ agmkin()

Agedge_t * agmkin ( Agedge_t e)

Definition at line 453 of file edge.c.

References AGMKIN.

◆ agmkout()

Agedge_t * agmkout ( Agedge_t e)

Definition at line 444 of file edge.c.

References AGMKOUT.

◆ agopp()

Agedge_t * agopp ( Agedge_t e)

Definition at line 480 of file edge.c.

References AGOPP.

◆ agtail()

Agnode_t * agtail ( Agedge_t e)

Definition at line 462 of file edge.c.

References AGTAIL.

◆ del()

static void del ( Dict_t d,
Dtlink_t **  set,
Agedge_t e 
)
static

Definition at line 156 of file edge.c.

References dtdelete, dtextract(), and dtrestore().

Referenced by agdeledgeimage(), diffeq_model(), finalCC(), make_flat_adj_edges(), makeStraightEdges(), parseSegs(), transformf(), and update_arrays().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ins()

static void ins ( Dict_t d,
Dtlink_t **  set,
Agedge_t e 
)
static

Definition at line 149 of file edge.c.

References dtextract(), dtinsert, and dtrestore().

Referenced by endBracket(), endString(), installedge(), interpretCRNL(), ps_string(), and stoj().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ installedge()

static void installedge ( Agraph_t g,
Agedge_t e 
)
static

Definition at line 166 of file edge.c.

References agfindedge_by_key(), aghead, AGMKIN, AGMKOUT, agparent(), agsubrep(), AGTAG, agtail, Agraph_s::e_id, Agraph_s::e_seq, Agsubnode_s::in_id, Agsubnode_s::in_seq, ins(), out(), Agsubnode_s::out_id, and Agsubnode_s::out_seq.

Referenced by agsubedge(), newedge(), and subedge().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ newedge()

static Agedge_t * newedge ( Agraph_t g,
Agnode_t t,
Agnode_t h,
IDTYPE  id 
)
static

Definition at line 194 of file edge.c.

References agalloc(), agbindrec(), AgDataRecName, AGEDGE, agedgeattr_init(), AGID, AGINEDGE, agmethod_init(), agnextseq(), AGOUTEDGE, AGSEQ, agsubnode(), AGTYPE, Agraph_s::desc, Agdesc_s::has_attrs, id, Agedgepair_s::in, installedge(), Agedge_s::node, out(), Agedgepair_s::out, and SEQ_MASK.

Referenced by agedge(), agidedge(), and gvbisect().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ok_to_make_edge()

static bool ok_to_make_edge ( Agraph_t g,
Agnode_t t,
Agnode_t h 
)
static

Definition at line 224 of file edge.c.

References agfindedge_by_key(), agisstrict(), Agraph_s::desc, key, Agdesc_s::no_loop, and Agtag_s::objtype.

Referenced by agedge(), and agidedge().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ subedge()

static void subedge ( Agraph_t g,
Agedge_t e 
)
static

Definition at line 188 of file edge.c.

References installedge().

Referenced by agedge(), and agidedge().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ Ag_mainedge_id_disc

Dtdisc_t Ag_mainedge_id_disc
Initial value:
= {
.link = offsetof(Agedge_t, id_link),
.comparf = agedgeidcmpf,
}
static int agedgeidcmpf(void *arg_e0, void *arg_e1)
Definition edge.c:376

Definition at line 419 of file edge.c.

Referenced by agopen1().

◆ Ag_mainedge_seq_disc

Dtdisc_t Ag_mainedge_seq_disc
Initial value:
= {
.link = offsetof(Agedge_t, seq_link),
.comparf = agedgeseqcmpf,
}
static int agedgeseqcmpf(void *arg_e0, void *arg_e1)
Definition edge.c:391

Definition at line 408 of file edge.c.

Referenced by agopen1().

◆ Ag_subedge_id_disc

Dtdisc_t Ag_subedge_id_disc
Initial value:
= {
.link = -1,
.comparf = agedgeidcmpf,
}

Definition at line 424 of file edge.c.

Referenced by agopen1().

◆ Ag_subedge_seq_disc

Dtdisc_t Ag_subedge_seq_disc
Initial value:
= {
.link = -1,
.comparf = agedgeseqcmpf,
}

Definition at line 413 of file edge.c.

Referenced by agopen1().