|
1 |
| |
|
2 |
| |
|
3 |
| package net.sourceforge.pmd.ast; |
|
4 |
| |
|
5 |
| public class ASTPrimarySuffix extends SimpleNode { |
|
6 |
0
| public ASTPrimarySuffix(int id) {
|
|
7 |
0
| super(id);
|
|
8 |
| } |
|
9 |
| |
|
10 |
401
| public ASTPrimarySuffix(JavaParser p, int id) {
|
|
11 |
401
| super(p, id);
|
|
12 |
| } |
|
13 |
| |
|
14 |
| private boolean isArguments; |
|
15 |
| private boolean isArrayDereference; |
|
16 |
| |
|
17 |
14
| public void setIsArrayDereference() {
|
|
18 |
14
| isArrayDereference = true;
|
|
19 |
| } |
|
20 |
| |
|
21 |
3
| public boolean isArrayDereference() {
|
|
22 |
3
| return isArrayDereference;
|
|
23 |
| } |
|
24 |
| |
|
25 |
330
| public void setIsArguments() {
|
|
26 |
330
| this.isArguments = true;
|
|
27 |
| } |
|
28 |
| |
|
29 |
401
| public boolean isArguments() {
|
|
30 |
401
| return this.isArguments;
|
|
31 |
| } |
|
32 |
| |
|
33 |
0
| public void dump(String prefix) {
|
|
34 |
0
| String out = "";
|
|
35 |
0
| if (isArrayDereference()) {
|
|
36 |
0
| out += ":[";
|
|
37 |
| } |
|
38 |
0
| if (this.getImage() != null) {
|
|
39 |
0
| out += out.length() == 0 ? ":" + this.getImage() : this.getImage();
|
|
40 |
| } |
|
41 |
0
| System.out.println(toString(prefix) + out);
|
|
42 |
0
| dumpChildren(prefix);
|
|
43 |
| } |
|
44 |
| |
|
45 |
| |
|
46 |
| |
|
47 |
1003
| public Object jjtAccept(JavaParserVisitor visitor, Object data) {
|
|
48 |
1003
| return visitor.visit(this, data);
|
|
49 |
| } |
|
50 |
| } |