org.fulib.scenarios.ast.expr.primary.IntLiteral Maven / Gradle / Ivy
Show all versions of fulibScenarios Show documentation
// Generated by GenTreeSrc v0.10.2
// DO NOT EDIT - CHANGES WILL BE LOST ON RE-GENERATE
package org.fulib.scenarios.ast.expr.primary;
import org.fulib.scenarios.ast.Node;
import org.fulib.scenarios.ast.Positioned;
import org.fulib.scenarios.ast.expr.Expr;
public interface IntLiteral extends PrimaryExpr
{
// =============== Static Methods ===============
static IntLiteral of(int value) { return new Impl(value); }
// =============== Properties ===============
int getValue();
void setValue(int value);
// =============== Methods ===============
default R accept(IntLiteral.Visitor
visitor, P par) { return visitor.visit(this, par); }
@Override default
R accept(PrimaryExpr.Visitor
visitor, P par) { return visitor.visit(this, par); }
@Override default
R accept(Expr.Visitor
visitor, P par) { return visitor.visit(this, par); }
@Override default
R accept(Positioned.Visitor
visitor, P par) { return visitor.visit(this, par); }
@Override default
R accept(Node.Visitor
visitor, P par) { return visitor.visit(this, par); }
// =============== Classes ===============
class Impl extends Positioned.Impl implements IntLiteral
{
// =============== Fields ===============
private int value;
// =============== Constructors ===============
public Impl() {}
public Impl(int value)
{
this.value = value;
}
// =============== Properties ===============
@Override public int getValue() { return this.value; }
@Override public void setValue(int value) { this.value = value; }
}
interface Visitor
{
// =============== Methods ===============
default R visit(IntLiteral intLiteral, P par) { throw new UnsupportedOperationException(this.getClass().getName() + ".visit(" + intLiteral.getClass().getName() + ")"); }
}
}