37 lines
828 B
Java
37 lines
828 B
Java
package be.jeffcheasey88.peeratcode.parser.java;
|
|
|
|
import java.util.List;
|
|
|
|
import be.jeffcheasey88.peeratcode.parser.Token;
|
|
|
|
public class Variable extends JavaElement{
|
|
|
|
private List<Annotation> annotations;
|
|
|
|
private int mod;
|
|
private Token type;
|
|
private Token name;
|
|
private boolean elips;
|
|
private Value value;
|
|
|
|
public Variable(int mod, Token type, Token name){
|
|
this.mod = mod;
|
|
this.type = type;
|
|
this.name = name;
|
|
}
|
|
|
|
public Variable(int mod, Token type, Token name, boolean elips){
|
|
this(mod, type, name);
|
|
this.elips = elips;
|
|
}
|
|
|
|
public Variable(int mod, Token type, Token name, boolean elips, Value value){
|
|
this(mod, type, name, elips);
|
|
this.value = value;
|
|
}
|
|
|
|
@Override
|
|
public String toString(){
|
|
return "Variable[mod="+mod+", type="+type+", name="+name+", elips="+elips+", value="+value+"]";
|
|
}
|
|
}
|