Debian Codegraph @

src/gen/lib/label/index__c.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 gen.lib.label;
47 import static gen.lib.label.node__c.AddBranch;
48 import static gen.lib.label.node__c.DisconBranch;
49 import static gen.lib.label.node__c.NodeCover;
50 import static gen.lib.label.node__c.PickBranch;
51 import static gen.lib.label.node__c.RTreeNewNode;
52 import static gen.lib.label.rectangle__c.CombineRect;
53 import static gen.lib.label.rectangle__c.Overlap;
54 import static smetana.core.JUtilsDebug.ENTERING;
55 import static smetana.core.JUtilsDebug.LEAVING;
56 import static smetana.core.Macro.N;
57 import static smetana.core.Macro.UNSUPPORTED;
58 import h.ST_Branch_t;
59 import h.ST_LeafList_t;
60 import h.ST_Node_t___;
61 import h.ST_Node_t___or_object_t;
62 import h.ST_RTree;
63 import h.ST_Rect_t;
64 import smetana.core.Memory;
65 import smetana.core.__ptr__;
66
67 public class index__c {
68
69
70 //3 1rfaqe5urty5uyp5xb2r0idce
71 // LeafList_t *RTreeNewLeafList(Leaf_t * lp)
72 public static ST_LeafList_t RTreeNewLeafList(ST_Branch_t lp) {
73 ENTERING("1rfaqe5urty5uyp5xb2r0idce","RTreeNewLeafList");
74 try {
75 ST_LeafList_t llp;
76 llp = new ST_LeafList_t();
77 llp.leaf = lp;
78 llp.next = null;
79 return llp;
80 //UNSUPPORTED("3b215c61vcll0rkorzyelp40j"); // if ((llp = (LeafList_t*)zmalloc(sizeof(LeafList_t)))) {
81 //UNSUPPORTED("48u04cv4b40c0avzy99mdycx5"); // llp->leaf = lp;
82 //UNSUPPORTED("bbvk7v1s0z6yw1xdoq99v233w"); // llp->next = 0;
83 //UNSUPPORTED("dvgyxsnyeqqnyzq696k3vskib"); // }
84 //UNSUPPORTED("5a1d3zolzdjict0gus6vz04a2"); // return llp;
85 //UNSUPPORTED("c24nfmv9i7o5eoqaymbibp7m7"); // }
86 //
87 //throw new UnsupportedOperationException();
88 } finally {
89 LEAVING("1rfaqe5urty5uyp5xb2r0idce","RTreeNewLeafList");
90 }
91 }
92
93
94
95
96 //3 6pvstz7axi8a7saeqe3nrrmg5
97 // LeafList_t *RTreeLeafListAdd(LeafList_t * llp, Leaf_t * lp)
98 public static ST_LeafList_t RTreeLeafListAdd(ST_LeafList_t llp, ST_Branch_t lp) {
99 ENTERING("6pvstz7axi8a7saeqe3nrrmg5","RTreeLeafListAdd");
100 try {
101 ST_LeafList_t nlp;
102 if (N(lp))
103 return llp;
104 nlp = RTreeNewLeafList(lp);
105 nlp.next = llp;
106 return nlp;
107 } finally {
108 LEAVING("6pvstz7axi8a7saeqe3nrrmg5","RTreeLeafListAdd");
109 }
110 }
111
112
113
114
115 //3 6zraor7x44vrnm19d2igkvow2
116 // void RTreeLeafListFree(LeafList_t * llp)
117 public static void RTreeLeafListFree(ST_LeafList_t llp) {
118 ENTERING("6zraor7x44vrnm19d2igkvow2","RTreeLeafListFree");
119 try {
120 ST_LeafList_t tlp;
121 while (llp.next!=null) {
122 tlp = (ST_LeafList_t) llp.next;
123 Memory.free(llp);
124 llp = tlp;
125 }
126 Memory.free(llp);
127 } finally {
128 LEAVING("6zraor7x44vrnm19d2igkvow2","RTreeLeafListFree");
129 }
130 }
131
132 ///* Allocate space for a node in the list used in DeletRect to
133 // * store Nodes that are too empty.
134 // */
135 //static struct ListNode *RTreeNewListNode(void)
136 //{
137 // return (struct ListNode*)zmalloc(sizeof(struct ListNode));
138 //}
139 //
140 ///* Add a node to the reinsertion list. All its branches will later
141 // * be reinserted into the index structure.
142 // */
143 //3 aa19m7d7qc06m8id896e60lkg
144 //static int RTreeReInsert(RTree_t * rtp, Node_t * n, struct ListNode **ee)
145 //{
146 // WARNING!! STRUCT
147 // register struct ListNode *l;
148 //
149 // if (!(l = RTreeNewListNode()))
150 // return -1;
151 // l->node = n;
152 // l->next = *ee;
153 // *ee = l;
154 // return 0;
155 //}
156 //
157 //3 aa29m7d7qc06m8id896e60lkg
158 //RTree_t *RTreeOpen()
159 public static __ptr__ RTreeOpen() {
160 ENTERING("aa29m7d7qc06m8id896e60lkg","RTreeOpen");
161 try {
162 ST_RTree rtp;
163 rtp = new ST_RTree();
164 if (rtp!=null)
165 rtp.setPtr("root", RTreeNewIndex(rtp));
166 return rtp;
167 } finally {
168 LEAVING("aa29m7d7qc06m8id896e60lkg","RTreeOpen");
169 }
170 }
171
172 /* Make a new index, empty. Consists of a single node. */
173 //3 aa39m7d7qc06m8id896e60lkg
174 //Node_t *RTreeNewIndex(RTree_t * rtp)
175 public static ST_Node_t___ RTreeNewIndex(ST_RTree rtp) {
176 ENTERING("aa39m7d7qc06m8id896e60lkg","RTreeNewIndex");
177 try {
178 ST_Node_t___ x;
179 x = RTreeNewNode(rtp);
180 x.setInt("level", 0); /* leaf */
181 rtp.setInt("LeafCount", rtp.LeafCount+1);
182 return x;
183 } finally {
184 LEAVING("aa39m7d7qc06m8id896e60lkg","RTreeNewIndex");
185 }
186 }
187
188 //3 aa49m7d7qc06m8id896e60lkg
189 //static int RTreeClose2(RTree_t * rtp, Node_t * n)
190 public static int RTreeClose2(ST_RTree rtp, ST_Node_t___ n) {
191 ENTERING("aa49m7d7qc06m8id896e60lkg","RTreeClose2");
192 try {
193 int i;
194
195 if (n.level > 0) {
196 for (i = 0; i < 64; i++) {
197 if (N(n.branch[i].child))
198 continue;
199 if (N(RTreeClose2(rtp, (ST_Node_t___) n.branch[i].child))) {
200 Memory.free(n.branch[i].child);
201 DisconBranch(n, i);
202 rtp.setInt("EntryCount", rtp.EntryCount-1);
203 if (rtp.StatFlag!=0)
204 rtp.setInt("ElimCount", rtp.ElimCount+1);
205 }
206 }
207 } else {
208 for (i = 0; i < 64; i++) {
209 if (N(n.branch[i].child))
210 continue;
211 // free(n->branch[i].child);
212 DisconBranch(n, i);
213 rtp.setInt("EntryCount", rtp.EntryCount-1);
214 if (rtp.StatFlag!=0)
215 rtp.setInt("ElimCount", rtp.ElimCount+1);
216 }
217 //free(n);
218 }
219 return 0;
220 } finally {
221 LEAVING("aa49m7d7qc06m8id896e60lkg","RTreeClose2");
222 }
223 }
224
225 //3 aa59m7d7qc06m8id896e60lkg
226 //int RTreeClose(RTree_t * rtp)
227 public static int RTreeClose(ST_RTree rtp) {
228 ENTERING("aa59m7d7qc06m8id896e60lkg","RTreeClose");
229 try {
230 RTreeClose2(rtp, (ST_Node_t___) rtp.root);
231 Memory.free(rtp.root);
232 Memory.free(rtp);
233 return 0;
234 } finally {
235 LEAVING("aa59m7d7qc06m8id896e60lkg","RTreeClose");
236 }
237 }
238
239
240
241 /* RTreeSearch in an index tree or subtree for all data retangles that
242 ** overlap the argument rectangle.
243 ** Returns the number of qualifying data rects.
244 */
245 //3 aa69m7d7qc06m8id896e60lkg
246 //LeafList_t *RTreeSearch(RTree_t * rtp, Node_t * n, Rect_t * r)
247 public static ST_LeafList_t RTreeSearch(ST_RTree rtp, ST_Node_t___ n, ST_Rect_t r) {
248 ENTERING("aa69m7d7qc06m8id896e60lkg","RTreeSearch");
249 try {
250 int i;
251 ST_LeafList_t llp = null;
252
253 // assert(n);
254 // assert(n->level >= 0);
255 // assert(r);
256
257 rtp.setInt("SeTouchCount", rtp.SeTouchCount+1);
258
259 if (n.level > 0) { /* this is an internal node in the tree */
260 for (i = 0; i < 64; i++)
261 if (n.branch[i].child!=null &&
262 Overlap(r, n.branch[i].rect)) {
263 ST_LeafList_t tlp = RTreeSearch(rtp, (ST_Node_t___) n.branch[i].child, r);
264 if (llp!=null) {
265 ST_LeafList_t xlp = llp;
266 while (xlp.next!=null)
267 xlp = (ST_LeafList_t) xlp.next;
268 xlp.next = tlp;
269 } else
270 llp = tlp;
271 }
272 } else { /* this is a leaf node */
273 for (i = 0; i < 64; i++) {
274 if (n.branch[i].child!=null && Overlap(r, n.branch[i].rect)) {
275 llp = RTreeLeafListAdd(llp, /*(Leaf_t *)*/ n.branch[i]);
276 }
277 }
278 }
279 return llp;
280 } finally {
281 LEAVING("aa69m7d7qc06m8id896e60lkg","RTreeSearch");
282 }
283 }
284
285 //}
286 //
287 ///* Insert a data rectangle into an index structure.
288 //** RTreeInsert provides for splitting the root;
289 //** returns 1 if root was split, 0 if it was not.
290 //** The level argument specifies the number of steps up from the leaf
291 //** level to insert; e.g. a data rectangle goes in at level = 0.
292 //** RTreeInsert2 does the recursion.
293 //*/
294 //static int RTreeInsert2(RTree_t *, Rect_t *, void *, Node_t *, Node_t **,
295 // int);
296 ///*static int RTreeInsert2(RTree_t*, Rect_t*, int, Node_t*, Node_t**, int); */
297
298
299
300 //3 3wss9r0zgt5k06j8ovjv7hq0d
301 // int RTreeInsert(RTree_t * rtp, Rect_t * r, void *data, Node_t ** n, int level)
302 public static int RTreeInsert(ST_RTree rtp, ST_Rect_t r, __ptr__ data, ST_Node_t___ n[], int level) {
303 ENTERING("3wss9r0zgt5k06j8ovjv7hq0d","RTreeInsert");
304 try {
305 int i;
306 ST_Node_t___ newroot;
307 ST_Node_t___ newnode[] = new ST_Node_t___[1];
308 final ST_Branch_t b = new ST_Branch_t();
309 int result = 0;
310 // assert(r && n);
311 // assert(level >= 0 && level <= (*n)->level);
312 // for (i = 0; i < 2; i++)
313 // assert(r->boundary[i] <= r->boundary[2 + i]);
314 if (rtp.StatFlag!=0) {
315 UNSUPPORTED("akhni40ndam0u9c6i7raxw4mp"); // if (rtp->Deleting)
316 UNSUPPORTED("bzb1oqc35evr96528iv16glb0"); // rtp->ReInsertCount++;
317 UNSUPPORTED("9352ql3e58qs4fzapgjfrms2s"); // else
318 UNSUPPORTED("3kxquse3qg2crme5dzybg9jxe"); // rtp->InsertCount++;
319 }
320 if (N(rtp.Deleting))
321 rtp.setInt("RectCount", rtp.RectCount+1);
322 if (RTreeInsert2(rtp, r, data, n[0], newnode, level)!=0) { /* root was split */
323 if (rtp.StatFlag!=0) {
324 UNSUPPORTED("2y8kv6b3ysrr61q7tqn76rhhc"); // if (rtp->Deleting)
325 UNSUPPORTED("dn4oynmx9ugizzs5pkxiyptbi"); // rtp->DeTouchCount++;
326 UNSUPPORTED("5c97f6vfxny0zz35l2bu4maox"); // else
327 UNSUPPORTED("2u8wpa4w1q7rg14t07bny6p8i"); // rtp->InTouchCount++;
328 }
329 newroot = RTreeNewNode(rtp); /* grow a new root, make tree taller */
330 rtp.setInt("NonLeafCount", rtp.NonLeafCount+1);
331 newroot.setInt("level", n[0].level + 1);
332 b.setStruct("rect", NodeCover(n[0]));
333 b.child = n[0];
334 AddBranch(rtp, b, newroot, null);
335 b.setStruct("rect", NodeCover(newnode[0]));
336 b.child = newnode[0];
337 AddBranch(rtp, b, newroot, null);
338 n[0] = newroot;
339 // rtp->root = newroot;
340 rtp.setInt("EntryCount", rtp.EntryCount + 2);
341 result = 1;
342 }
343 return result;
344 } finally {
345 LEAVING("3wss9r0zgt5k06j8ovjv7hq0d","RTreeInsert");
346 }
347 }
348
349
350
351 // public static int RTreeInsert(ST_RTree rtp, ST_Rect_t r, __ptr__ data, ST_Node_t___ n[], int level) {
352
353 //3 bsc9m7d7qc06m8id896e60lkg
354 // static int RTreeInsert2(RTree_t * rtp, Rect_t * r, void *data, Node_t * n, Node_t ** new, int level)
355 public static int RTreeInsert2(ST_RTree rtp, ST_Rect_t r, __ptr__ data, ST_Node_t___ n, ST_Node_t___ new_[], int level) {
356 ENTERING("bsc9m7d7qc06m8id896e60lkg","RTreeInsert2");
357 try {
358 /*static int */
359 /* RTreeInsert2(RTree_t*rtp, Rect_t*r,
360 int data, Node_t*n, Node_t**new, int level) {
361 */
362 int i=0;
363 final ST_Branch_t b = new ST_Branch_t();
364 ST_Node_t___ n2[]=new ST_Node_t___[1];
365 // assert(r && n && new);
366 // assert(level >= 0 && level <= n->level);
367 if (rtp.StatFlag!=0) {
368 UNSUPPORTED("akhni40ndam0u9c6i7raxw4mp"); // if (rtp->Deleting)
369 UNSUPPORTED("8k1kgaoa4b2mcye1xthc3f1kf"); // rtp->DeTouchCount++;
370 UNSUPPORTED("9352ql3e58qs4fzapgjfrms2s"); // else
371 UNSUPPORTED("1um729vqiy3529kbsrzyl9u3y"); // rtp->InTouchCount++;
372 }
373 /* Still above level for insertion, go down tree recursively */
374 if (n.level > level) {
375 i = PickBranch(r, n);
376 if (N(RTreeInsert2(rtp, r, data, (ST_Node_t___) n.branch[i].child, n2, level))) {
377 /* recurse: child was not split */
378 n.branch[i].setStruct("rect",
379 CombineRect((ST_Rect_t)r, (ST_Rect_t) n.branch[i].rect));
380 return 0;
381 } else { /* child was split */
382 n.branch[i].setStruct("rect",
383 NodeCover((ST_Node_t___)n.branch[i].child));
384 b.child = n2[0];
385 b.rect.___(NodeCover(n2[0]));
386 rtp.setInt("EntryCount", rtp.EntryCount+1);
387 return AddBranch(rtp, b, n, new_);
388 }
389 } else if (n.level == level) { /* at level for insertion. */
390 /*Add rect, split if necessary */
391 b.rect.___(r);
392 b.child = /*(Node_t *)*/(ST_Node_t___or_object_t) data; // THIS CAST IS A BIG ISSUE
393 // UNSUPPORTED("7w1b5nw2bj3zmo70m9bczwwov"); // b.child = (Node_t *) data;
394 rtp.setInt("EntryCount", rtp.EntryCount+1);
395 return AddBranch(rtp, b, n, new_);
396 } else { /* Not supposed to happen */
397 UNSUPPORTED("22oqraxnqrjall7fj6pooexmi"); // assert((0));
398 UNSUPPORTED("c9ckhc8veujmwcw0ar3u3zld4"); // return 0;
399 }
400 throw new UnsupportedOperationException();
401 } finally {
402 LEAVING("bsc9m7d7qc06m8id896e60lkg","RTreeInsert2");
403 }
404 }
405
406
407
408
409 //3 eybi74pqddw71yno71n1dxch1
410 // static void FreeListNode(register struct ListNode *p)
411 public static Object FreeListNode(Object... arg) {
412 UNSUPPORTED("enkn7pc4meks3igihpafaoxnl"); // static void FreeListNode(register struct ListNode *p)
413 UNSUPPORTED("erg9i1970wdri39osu8hx2a6e"); // {
414 UNSUPPORTED("bo0y3vz195pcz24vm46pixpb2"); // free(p);
415 UNSUPPORTED("c24nfmv9i7o5eoqaymbibp7m7"); // }
416
417 throw new UnsupportedOperationException();
418 }
419
420
421
422
423 //3 a4tq9skwvzdutka9ei6pbydrk
424 // int RTreeDelete(RTree_t * rtp, Rect_t * r, void *data, Node_t ** nn)
425 public static Object RTreeDelete(Object... arg) {
426 UNSUPPORTED("dxan13j7zc5tysdskndrhp0jy"); // int RTreeDelete(RTree_t * rtp, Rect_t * r, void *data, Node_t ** nn)
427 UNSUPPORTED("erg9i1970wdri39osu8hx2a6e"); // {
428 UNSUPPORTED("a12nb5dbhoiu403g443fctkns"); // /* int */
429 UNSUPPORTED("db7nkyc7g4zod4pcosw0eosmi"); // /* RTreeDelete(RTree_t*rtp, Rect_t*r, int data, Node_t**nn) { */
430 UNSUPPORTED("pp6gyv6pecd6kik4hoguluwp"); // register int i;
431 UNSUPPORTED("ben8zsxtpzeiqo8eli2l8uwl0"); // register Node_t *t;
432 UNSUPPORTED("5pdj91y3888dsu9aiv163adqi"); // struct ListNode *reInsertList = (void *)0;
433 UNSUPPORTED("ej513ottpyeoq8nr5ek3cqnyu"); // register struct ListNode *e;
434 UNSUPPORTED("9fgs287rhe40d3q36tlijajk3"); // assert(r && nn);
435 UNSUPPORTED("djo1drf8zqgd4dlmtnp8268ma"); // assert(*nn);
436 UNSUPPORTED("aickurv6sbkajrl6u32h8s7n0"); // assert(data >= 0);
437 UNSUPPORTED("d7p6had3bhs1yux0acgomhxcq"); // rtp->Deleting = (!(0));
438 UNSUPPORTED("607lavmustb15rxzq2849utq7"); // if (!RTreeDelete2(rtp, r, data, *nn, &reInsertList)) {
439 UNSUPPORTED("78928a78vetdygse25vd6qw33"); // /* found and deleted a data item */
440 UNSUPPORTED("bi6ay2t4s62zfticozlr791yq"); // if (rtp->StatFlag)
441 UNSUPPORTED("aiqjtlu1lbfame9tsdduxksph"); // rtp->DeleteCount++;
442 UNSUPPORTED("337cl2y5ymgyje4han1uiddia"); // rtp->RectCount--;
443 UNSUPPORTED("dm3fsqsr312twcwr7ejz72sd5"); // /* reinsert any branches from eliminated nodes */
444 UNSUPPORTED("3miqozg3j3sz0440ya0edtkn1"); // while (reInsertList) {
445 UNSUPPORTED("8bi7drdkfhozlzpnr9a8beo9r"); // t = reInsertList->node;
446 UNSUPPORTED("ehzcswv2o675ah20nlk8ll73b"); // for (i = 0; i < 64; i++) {
447 UNSUPPORTED("16k4a0oof3m3shq22rp10sufm"); // if (t->branch[i].child) {
448 UNSUPPORTED("4pmqw3ejoeiktbmgw5li4osuk"); // RTreeInsert(rtp, &(t->branch[i].rect),
449 UNSUPPORTED("jn668g7qkg8vdom23tf6xyua"); // /* (int)t->branch[i].child, nn, t->level); */
450 UNSUPPORTED("cr2tz58k73uenuatj8dllr5e"); // t->branch[i].child, nn, t->level);
451 UNSUPPORTED("3ll931j526x4h3iq2n8lb8npl"); // rtp->EntryCount--;
452 UNSUPPORTED("6eq5kf0bj692bokt0bixy1ixh"); // }
453 UNSUPPORTED("6t98dcecgbvbvtpycwiq2ynnj"); // }
454 UNSUPPORTED("a0driook10zxazzgo71kxwf5t"); // e = reInsertList;
455 UNSUPPORTED("3ycjjmywhr2h58szv9f0c3r67"); // reInsertList = reInsertList->next;
456 UNSUPPORTED("2l03pg61762f3m81wcifv6o2t"); // RTreeFreeNode(rtp, e->node);
457 UNSUPPORTED("2nfqlmqqiafmfh2uxj5r72e5z"); // FreeListNode(e);
458 UNSUPPORTED("flupwh3kosf3fkhkxllllt1"); // }
459 UNSUPPORTED("3uomzgqvjm03fwau1petngub8"); // /* check for redundant root (not leaf, 1 child) and eliminate */
460 UNSUPPORTED("crynploao8fgrtf7envjtfdaz"); // if ((*nn)->count == 1 && (*nn)->level > 0) {
461 UNSUPPORTED("a588ej7tdnabye2dhwn96zbay"); // if (rtp->StatFlag)
462 UNSUPPORTED("4bzchhtuz1r199e9mi0bp1ece"); // rtp->ElimCount++;
463 UNSUPPORTED("6u2n1qlqovrhoecwygc6fuq2c"); // rtp->EntryCount--;
464 UNSUPPORTED("ehzcswv2o675ah20nlk8ll73b"); // for (i = 0; i < 64; i++) {
465 UNSUPPORTED("jk2oyzi48hf05v99gu6wc2o2"); // if ((t = (*nn)->branch[i].child))
466 UNSUPPORTED("czyohktf9bkx4udfqhx42f4lu"); // break;
467 UNSUPPORTED("6t98dcecgbvbvtpycwiq2ynnj"); // }
468 UNSUPPORTED("5ba1w7saym0g246ykbjnn0qrf"); // RTreeFreeNode(rtp, *nn);
469 UNSUPPORTED("dnoogjer2v3hmfm7qtw2p4qrv"); // *nn = t;
470 UNSUPPORTED("flupwh3kosf3fkhkxllllt1"); // }
471 UNSUPPORTED("cpwomgmpysmof2uglfr37v494"); // rtp->Deleting = (0);
472 UNSUPPORTED("c9ckhc8veujmwcw0ar3u3zld4"); // return 0;
473 UNSUPPORTED("c07up7zvrnu2vhzy6d7zcu94g"); // } else {
474 UNSUPPORTED("cpwomgmpysmof2uglfr37v494"); // rtp->Deleting = (0);
475 UNSUPPORTED("eleqpc2p2r3hvma6tipoy7tr"); // return 1;
476 UNSUPPORTED("dvgyxsnyeqqnyzq696k3vskib"); // }
477 UNSUPPORTED("c24nfmv9i7o5eoqaymbibp7m7"); // }
478
479 throw new UnsupportedOperationException();
480 }
481
482
483
484
485 //3 bax12o5n6n8s94wnn7cxgn99
486 // static int RTreeDelete2(RTree_t * rtp, Rect_t * r, void *data, Node_t * n, ListNode_t ** ee)
487 public static Object RTreeDelete2(Object... arg) {
488 UNSUPPORTED("eyp5xkiyummcoc88ul2b6tkeg"); // static int
489 UNSUPPORTED("dl163ikex89epdeiymlnlhkkt"); // RTreeDelete2(RTree_t * rtp, Rect_t * r, void *data, Node_t * n,
490 UNSUPPORTED("7cv8lwqbi5i6si9trbnke7zl9"); // ListNode_t ** ee)
491 UNSUPPORTED("8suowst9wgd6gxhgbdi3h24b7"); // /* static int */
492 UNSUPPORTED("ap2yhjmvw1l4wh1rujus8t8ef"); // /* RTreeDelete2(RTree_t*rtp, Rect_t*r, int data, Node_t*n, ListNode_t**ee) */
493 UNSUPPORTED("erg9i1970wdri39osu8hx2a6e"); // {
494 UNSUPPORTED("pp6gyv6pecd6kik4hoguluwp"); // register int i;
495 UNSUPPORTED("9yzorirytkswjf0omka5g4c20"); // assert(r && n && ee);
496 UNSUPPORTED("aickurv6sbkajrl6u32h8s7n0"); // assert(data >= 0);
497 UNSUPPORTED("btdpzkb56pz41hfftabazxn4s"); // assert(n->level >= 0);
498 UNSUPPORTED("c435v08qyezw1xnbv2zrqr3te"); // if (rtp->StatFlag)
499 UNSUPPORTED("9qx61yt5qzelxylomit9cn4rv"); // rtp->DeTouchCount++;
500 UNSUPPORTED("5zjfl81difxhf334pznet7o8z"); // if (n->level > 0) { /* not a leaf node */
501 UNSUPPORTED("r6wug9hvutzrx2jp04v9slbe"); // for (i = 0; i < 64; i++) {
502 UNSUPPORTED("9cxgoq0fd8kxz4eymv34vt66k"); // if (n->branch[i].child && Overlap(r, &(n->branch[i].rect))) {
503 UNSUPPORTED("9c2dxowbn34szo9si1s67zn1d"); // if (!RTreeDelete2(rtp, r, data, n->branch[i].child, ee)) { /*recurse */
504 UNSUPPORTED("1p8d3xzz5d8g7ach93r5dkfpy"); // if (n->branch[i].child->count >= rtp->MinFill)
505 UNSUPPORTED("8qc1vxcpq7d0q3d4pt56sagi6"); // n->branch[i].rect = NodeCover(n->branch[i].child);
506 UNSUPPORTED("1pj51sbe7du437gcgun1tdp0c"); // else { /* not enough entries in child, eliminate child node */
507 UNSUPPORTED("1mqsg2rc7oaykxyne9jioil3j"); // RTreeReInsert(rtp, n->branch[i].child, ee);
508 UNSUPPORTED("36htmotk6j7fq59vwfp4lanaj"); // DisconBranch(n, i);
509 UNSUPPORTED("614qavwsv6dpxdog4wxkb2op0"); // rtp->EntryCount--;
510 UNSUPPORTED("ad48i843uruoaahfmd2nxb4qv"); // if (rtp->StatFlag)
511 UNSUPPORTED("jk9sg727bbh6mlccfj53sg1m"); // rtp->ElimCount++;
512 UNSUPPORTED("dkxvw03k2gg9anv4dbze06axd"); // }
513 UNSUPPORTED("y2l9mpq5754ggnklm39b7wg"); // return 0;
514 UNSUPPORTED("6eq5kf0bj692bokt0bixy1ixh"); // }
515 UNSUPPORTED("6t98dcecgbvbvtpycwiq2ynnj"); // }
516 UNSUPPORTED("flupwh3kosf3fkhkxllllt1"); // }
517 UNSUPPORTED("eleqpc2p2r3hvma6tipoy7tr"); // return 1;
518 UNSUPPORTED("dppt1v5lkz1rfqbwx4n4xwltd"); // } else { /* a leaf node */
519 UNSUPPORTED("r6wug9hvutzrx2jp04v9slbe"); // for (i = 0; i < 64; i++) {
520 UNSUPPORTED("5g2zznotye25yuclpeyzatgrf"); // if (n->branch[i].child
521 UNSUPPORTED("dx5d5kpda621ehao92qybpo7n"); // && n->branch[i].child == (Node_t *) data) {
522 UNSUPPORTED("3nnhyf15i3s8j44ptc0zjxkof"); // DisconBranch(n, i);
523 UNSUPPORTED("cazijll74xx4uxev9qe61vl0h"); // rtp->EntryCount--;
524 UNSUPPORTED("5izxoao5ryte71964f8yjfd5y"); // return 0;
525 UNSUPPORTED("6t98dcecgbvbvtpycwiq2ynnj"); // }
526 UNSUPPORTED("flupwh3kosf3fkhkxllllt1"); // }
527 UNSUPPORTED("eleqpc2p2r3hvma6tipoy7tr"); // return 1;
528 UNSUPPORTED("dvgyxsnyeqqnyzq696k3vskib"); // }
529 UNSUPPORTED("c24nfmv9i7o5eoqaymbibp7m7"); // }
530
531 throw new UnsupportedOperationException();
532 }
533
534
535 }