Debian Codegraph @

src/h/ST_Agedgeinfo_t.java

raw symbols SCIP
1 /* ========================================================================
2 * PlantUML : a free UML diagram generator
3 * ========================================================================
4 *
5 * Project Info: http://plantuml.com
6 *
7 * If you like this project or if you find it useful, you can support us at:
8 *
9 * http://plantuml.com/patreon (only 1$ per month!)
10 * http://plantuml.com/paypal
11 *
12 * This file is part of Smetana.
13 * Smetana is a partial translation of Graphviz/Dot sources from C to Java.
14 *
15 * (C) Copyright 2009-2020, Arnaud Roques
16 *
17 * This translation is distributed under the same Licence as the original C program:
18 *
19 *************************************************************************
20 * Copyright (c) 2011 AT&T Intellectual Property
21 * All rights reserved. This program and the accompanying materials
22 * are made available under the terms of the Eclipse Public License v1.0
23 * which accompanies this distribution, and is available at
24 * http://www.eclipse.org/legal/epl-v10.html
25 *
26 * Contributors: See CVS logs. Details at http://www.graphviz.org/
27 *************************************************************************
28 *
29 * THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC
30 * LICENSE ("AGREEMENT"). [Eclipse Public License - v 1.0]
31 *
32 * ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES
33 * RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT.
34 *
35 * You may obtain a copy of the License at
36 *
37 * http://www.eclipse.org/legal/epl-v10.html
38 *
39 * Unless required by applicable law or agreed to in writing, software
40 * distributed under the License is distributed on an "AS IS" BASIS,
41 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
42 * See the License for the specific language governing permissions and
43 * limitations under the License.
44 *
45 */
46 package h;
47
48 import smetana.core.UnsupportedStructAndPtr;
49 import smetana.core.__ptr__;
50 import smetana.core.__struct__;
51 import smetana.core.amiga.StarStruct;
52
53 public class ST_Agedgeinfo_t extends UnsupportedStructAndPtr {
54
55 private final StarStruct parent;
56
57 public ST_Agedgeinfo_t() {
58 this(null);
59 }
60
61 public ST_Agedgeinfo_t(StarStruct parent) {
62 this.parent = parent;
63 }
64
65 public final ST_Agrec_s hdr = new ST_Agrec_s(this);
66
67 public ST_splines spl;
68 public final ST_port tail_port = new ST_port(this), head_port = new ST_port(this);
69 public ST_textlabel_t label, head_label, tail_label, xlabel;
70 public int edge_type;
71 public int adjacent;
72 public boolean label_ontop;
73 // "unsigned char gui_state",
74 public ST_Agedge_s to_orig;
75 // "void *alg",
76 // "double factor",
77 public double dist;
78 // "Ppolyline_t path",
79 public int showboxes;
80 public boolean conc_opp_flag;
81 public int xpenalty;
82 public int weight;
83 public int cutvalue, tree_index;
84 public int count;
85 public int minlen;
86
87 public ST_Agedge_s to_virt;
88
89 @Override
90 public void copyDataFrom(__struct__ other) {
91 ST_Agedgeinfo_t this2 = (ST_Agedgeinfo_t) other;
92 this.hdr.copyDataFrom((__struct__) this2.hdr);
93 this.spl = this2.spl;
94 this.tail_port.copyDataFrom((__struct__) this2.tail_port);
95 this.head_port.copyDataFrom((__struct__) this2.head_port);
96 this.label = this2.label;
97 this.head_label = this2.head_label;
98 this.tail_label = this2.tail_label;
99 this.xlabel = this2.xlabel;
100 this.edge_type = this2.edge_type;
101 this.adjacent = this2.adjacent;
102 this.label_ontop = this2.label_ontop;
103 this.to_orig = this2.to_orig;
104 this.dist = this2.dist;
105 this.showboxes = this2.showboxes;
106 this.conc_opp_flag = this2.conc_opp_flag;
107 this.xpenalty = this2.xpenalty;
108 this.weight = this2.weight;
109 this.cutvalue = this2.cutvalue;
110 this.tree_index = this2.tree_index;
111 this.count = this2.count;
112 this.minlen = this2.minlen;
113 this.to_virt = this2.to_virt;
114 }
115
116 @Override
117 public __ptr__ castTo(Class dest) {
118 if (dest == ST_Agrec_s.class) {
119 return hdr;
120 }
121 if (dest == ST_Agedgeinfo_t.class) {
122 return this;
123 }
124 return super.castTo(dest);
125 }
126
127 @Override
128 public void setStruct(String fieldName, __struct__ newData) {
129 if (fieldName.equals("tail_port")) {
130 this.tail_port.copyDataFrom(newData);
131 return;
132 }
133 if (fieldName.equals("head_port")) {
134 this.head_port.copyDataFrom(newData);
135 return;
136 }
137 super.setStruct(fieldName, newData);
138 }
139
140 @Override
141 public void setDouble(String fieldName, double data) {
142 if (fieldName.equals("dist")) {
143 this.dist = data;
144 return;
145 }
146 super.setDouble(fieldName, data);
147 }
148
149 @Override
150 public void setInt(String fieldName, int data) {
151 if (fieldName.equals("minlen")) {
152 this.minlen = data;
153 return;
154 }
155 if (fieldName.equals("weight")) {
156 this.weight = data;
157 return;
158 }
159 if (fieldName.equals("cutvalue")) {
160 this.cutvalue = data;
161 return;
162 }
163 if (fieldName.equals("tree_index")) {
164 this.tree_index = data;
165 return;
166 }
167 if (fieldName.equals("count")) {
168 this.count = data;
169 return;
170 }
171 if (fieldName.equals("xpenalty")) {
172 this.xpenalty = data;
173 return;
174 }
175 if (fieldName.equals("showboxes")) {
176 this.showboxes = data;
177 return;
178 }
179 if (fieldName.equals("edge_type")) {
180 this.edge_type = data;
181 return;
182 }
183 if (fieldName.equals("adjacent")) {
184 this.adjacent = data;
185 return;
186 }
187 super.setInt(fieldName, data);
188 }
189
190
191 @Override
192 public __ptr__ setPtr(String fieldName, __ptr__ newData) {
193 if (fieldName.equals("to_virt")) {
194 this.to_virt = (ST_Agedge_s) newData;
195 return this.to_virt;
196 }
197 if (fieldName.equals("to_orig")) {
198 this.to_orig = (ST_Agedge_s) newData;
199 return this.to_orig;
200 }
201 if (fieldName.equals("spl")) {
202 this.spl = (ST_splines) newData;
203 return this.spl;
204 }
205 if (fieldName.equals("label")) {
206 this.label = (ST_textlabel_t) newData;
207 return this.label;
208 }
209 if (fieldName.equals("head_label")) {
210 this.head_label = (ST_textlabel_t) newData;
211 return this.head_label;
212 }
213 if (fieldName.equals("tail_label")) {
214 this.tail_label = (ST_textlabel_t) newData;
215 return this.tail_label;
216 }
217 return super.setPtr(fieldName, newData);
218 }
219
220 @Override
221 public __struct__ getStruct() {
222 return this;
223 }
224
225 }
226
227 // typedef struct Agedgeinfo_t {
228 // Agrec_t hdr;
229 // splines *spl;
230 // port tail_port, head_port;
231 // textlabel_t *label, *head_label, *tail_label, *xlabel;
232 // char edge_type;
233 // char adjacent; /* true for flat edge with adjacent nodes */
234 // char label_ontop;
235 // unsigned char gui_state; /* Edge state for GUI ops */
236 // edge_t *to_orig; /* for dot's shapes.c */
237 // void *alg;
238 //
239 //
240 // double factor;
241 // double dist;
242 // Ppolyline_t path;
243 //
244 //
245 // unsigned char showboxes;
246 // boolean conc_opp_flag;
247 // short xpenalty;
248 // int weight;
249 // int cutvalue, tree_index;
250 // short count;
251 // unsigned short minlen;
252 // edge_t *to_virt;
253 //
254 // } Agedgeinfo_t;