2
This software may only be used by you under license from AT&T Corp.
3
("AT&T"). A copy of AT&T's Source Code Agreement is available at
4
AT&T's Internet website having the URL:
5
<http://www.research.att.com/sw/tools/graphviz/license/source.html>
6
If you received this software without first entering into a license
7
with AT&T, you have an infringing copy of this software and cannot use
8
it without violating AT&T's intellectual property rights.
18
static Agraph_t *Ag_dictop_G;
20
/* only indirect call through dtopen() is expected */
21
void *agdictobjmem(Dict_t *dict, Void_t *p, size_t size, Dtdisc_t *disc)
30
else return agalloc(g,size);
34
else return malloc(size);
39
void agdictobjfree(Dict_t *dict, Void_t *p, Dtdisc_t *disc)
43
NOTUSED(dict); NOTUSED(disc);
49
Dict_t *agdtopen(Agraph_t *g, Dtdisc_t *disc, Dtmethod_t *method)
55
disc->memoryf = agdictobjmem;
57
d = dtopen(disc,method);
62
long agdtdelete(Agraph_t *g, Dict_t *dict, void *obj)
65
return (long)dtdelete(dict,obj);
68
int agobjfinalize(Void_t *obj)
70
agfree(Ag_dictop_G,obj);
74
void agdtclose(Agraph_t *g, Dict_t *dict)
79
disc = dtdisc(dict,NIL(Dtdisc_t*),0);
81
disc->memoryf = agdictobjmem;
83
if (dtclose(dict)) abort();
87
void agdtdisc(Agraph_t *g, Dict_t *dict, Dtdisc_t *disc)
89
if (disc && (dtdisc(dict,NIL(Dtdisc_t*),0) != disc)) {
93
/* else unchanged, disc is same as old disc */