1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
package org.kuali.student.common.messagebuilder.booleanmessage.ast; |
17 |
|
|
18 |
|
import org.antlr.runtime.Token; |
19 |
|
import org.antlr.runtime.tree.CommonTree; |
20 |
|
|
21 |
|
|
22 |
|
|
23 |
|
|
|
|
| 0% |
Uncovered Elements: 32 (32) |
Complexity: 16 |
Complexity Density: 1.23 |
|
24 |
|
public class BooleanNode extends CommonTree { |
25 |
|
|
26 |
|
private BooleanNode parent; |
27 |
|
private Boolean value; |
28 |
|
private String nodeMessage; |
29 |
|
private String language; |
30 |
|
|
31 |
|
|
32 |
|
|
33 |
|
|
34 |
|
|
35 |
|
|
36 |
|
@param |
37 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
38 |
0
|
public BooleanNode(Token payload) {... |
39 |
0
|
super(payload); |
40 |
|
} |
41 |
|
|
42 |
|
|
43 |
|
|
44 |
|
|
45 |
|
@return |
46 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
47 |
0
|
public BooleanNode getParent(){... |
48 |
0
|
return parent; |
49 |
|
} |
50 |
|
|
51 |
|
|
52 |
|
|
53 |
|
|
54 |
|
@return |
55 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
56 |
0
|
public BooleanNode getLeftNode(){... |
57 |
0
|
return (BooleanNode) this.getChild(0); |
58 |
|
} |
59 |
|
|
60 |
|
|
61 |
|
|
62 |
|
|
63 |
|
@return |
64 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
65 |
0
|
public BooleanNode getRightNode(){... |
66 |
0
|
return (BooleanNode) this.getChild(1); |
67 |
|
} |
68 |
|
|
69 |
|
|
70 |
|
|
71 |
|
|
72 |
|
@return |
73 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
74 |
0
|
public String getLabel(){... |
75 |
0
|
return this.getText(); |
76 |
|
} |
77 |
|
|
78 |
|
|
79 |
|
|
80 |
|
|
81 |
|
@return |
82 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
83 |
0
|
public Boolean getValue(){... |
84 |
0
|
return value; |
85 |
|
} |
86 |
|
|
87 |
|
|
88 |
|
|
89 |
|
|
90 |
|
@return |
91 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
92 |
0
|
public String getNodeMessage(){... |
93 |
0
|
return nodeMessage; |
94 |
|
} |
95 |
|
|
96 |
|
|
97 |
|
|
98 |
|
|
99 |
|
@return |
100 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
101 |
0
|
public String getLanguage() {... |
102 |
0
|
return language; |
103 |
|
} |
104 |
|
|
105 |
|
|
106 |
|
|
107 |
|
|
108 |
|
|
109 |
|
@param |
110 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
111 |
0
|
public void setParent(BooleanNode parent){... |
112 |
0
|
this.parent = parent; |
113 |
|
} |
114 |
|
|
115 |
|
|
116 |
|
|
117 |
|
|
118 |
|
@param |
119 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
120 |
0
|
public void setValue(Boolean value){... |
121 |
0
|
this.value = value; |
122 |
|
} |
123 |
|
|
124 |
|
|
125 |
|
|
126 |
|
|
127 |
|
@param |
128 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
129 |
0
|
public void setNodeMessage(String nodeMessage){... |
130 |
0
|
this.nodeMessage = nodeMessage; |
131 |
|
} |
132 |
|
|
133 |
|
|
134 |
|
|
135 |
|
|
136 |
|
@param |
137 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
138 |
0
|
public void setLanguage(String language) {... |
139 |
0
|
this.language = language; |
140 |
|
} |
141 |
|
|
|
|
| 0% |
Uncovered Elements: 7 (7) |
Complexity: 4 |
Complexity Density: 4 |
|
142 |
0
|
@Override... |
143 |
|
public String toString() { |
144 |
0
|
return "BooleanNode[" |
145 |
|
+ "label=" + getLabel() |
146 |
|
+ ", value=" + value |
147 |
0
|
+ ", leftNodeLabel=" + (getLeftNode() == null ? null : getLeftNode().getLabel()) |
148 |
0
|
+ ", rightNodeLabel=" + (getRightNode() == null ? null : getRightNode().getLabel()) |
149 |
0
|
+ ", parentLabel=" + (parent == null ? null : parent.getLabel()) |
150 |
|
+ "]"; |
151 |
|
} |
152 |
|
|
153 |
|
} |