1
2
3
4
5
6
7
8
9 package org.gnu.glpk;
10
11
12
13
14
15
16
17
18
19 public class glp_arc {
20 private transient long swigCPtr;
21 protected transient boolean swigCMemOwn;
22
23 protected glp_arc(long cPtr, boolean cMemoryOwn) {
24 swigCMemOwn = cMemoryOwn;
25 swigCPtr = cPtr;
26 }
27
28 protected static long getCPtr(glp_arc obj) {
29 return (obj == null) ? 0 : obj.swigCPtr;
30 }
31
32 protected void finalize() {
33 delete();
34 }
35
36 public synchronized void delete() {
37 if (swigCPtr != 0) {
38 if (swigCMemOwn) {
39 swigCMemOwn = false;
40 GLPKJNI.delete_glp_arc(swigCPtr);
41 }
42 swigCPtr = 0;
43 }
44 }
45
46 public void setTail(glp_vertex value) {
47 GLPKJNI.glp_arc_tail_set(swigCPtr, glp_vertex.getCPtr(value), value);
48 }
49
50 public glp_vertex getTail() {
51 long cPtr = GLPKJNI.glp_arc_tail_get(swigCPtr);
52 return (cPtr == 0) ? null : new glp_vertex(cPtr, false);
53 }
54
55 public void setHead(glp_vertex value) {
56 GLPKJNI.glp_arc_head_set(swigCPtr, glp_vertex.getCPtr(value), value);
57 }
58
59 public glp_vertex getHead() {
60 long cPtr = GLPKJNI.glp_arc_head_get(swigCPtr);
61 return (cPtr == 0) ? null : new glp_vertex(cPtr, false);
62 }
63
64 public void setData(SWIGTYPE_p_void value) {
65 GLPKJNI.glp_arc_data_set(swigCPtr, SWIGTYPE_p_void.getCPtr(value));
66 }
67
68 public SWIGTYPE_p_void getData() {
69 long cPtr = GLPKJNI.glp_arc_data_get(swigCPtr);
70 return (cPtr == 0) ? null : new SWIGTYPE_p_void(cPtr, false);
71 }
72
73 public void setTemp(SWIGTYPE_p_void value) {
74 GLPKJNI.glp_arc_temp_set(swigCPtr, SWIGTYPE_p_void.getCPtr(value));
75 }
76
77 public SWIGTYPE_p_void getTemp() {
78 long cPtr = GLPKJNI.glp_arc_temp_get(swigCPtr);
79 return (cPtr == 0) ? null : new SWIGTYPE_p_void(cPtr, false);
80 }
81
82 public void setT_prev(glp_arc value) {
83 GLPKJNI.glp_arc_t_prev_set(swigCPtr, glp_arc.getCPtr(value), value);
84 }
85
86 public glp_arc getT_prev() {
87 long cPtr = GLPKJNI.glp_arc_t_prev_get(swigCPtr);
88 return (cPtr == 0) ? null : new glp_arc(cPtr, false);
89 }
90
91 public void setT_next(glp_arc value) {
92 GLPKJNI.glp_arc_t_next_set(swigCPtr, glp_arc.getCPtr(value), value);
93 }
94
95 public glp_arc getT_next() {
96 long cPtr = GLPKJNI.glp_arc_t_next_get(swigCPtr);
97 return (cPtr == 0) ? null : new glp_arc(cPtr, false);
98 }
99
100 public void setH_prev(glp_arc value) {
101 GLPKJNI.glp_arc_h_prev_set(swigCPtr, glp_arc.getCPtr(value), value);
102 }
103
104 public glp_arc getH_prev() {
105 long cPtr = GLPKJNI.glp_arc_h_prev_get(swigCPtr);
106 return (cPtr == 0) ? null : new glp_arc(cPtr, false);
107 }
108
109 public void setH_next(glp_arc value) {
110 GLPKJNI.glp_arc_h_next_set(swigCPtr, glp_arc.getCPtr(value), value);
111 }
112
113 public glp_arc getH_next() {
114 long cPtr = GLPKJNI.glp_arc_h_next_get(swigCPtr);
115 return (cPtr == 0) ? null : new glp_arc(cPtr, false);
116 }
117
118 public glp_arc() {
119 this(GLPKJNI.new_glp_arc(), true);
120 }
121
122 }