Package org.esa.snap.core.jexp
Class Term.Ref
- java.lang.Object
-
- org.esa.snap.core.jexp.Term
-
- org.esa.snap.core.jexp.Term.Ref
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.esa.snap.core.jexp.Term
Term.Add, Term.AndB, Term.AndI, Term.Assign, Term.Binary, Term.BinaryB, Term.BinaryI, Term.BinaryN, Term.Call, Term.Cond, Term.Const, Term.ConstB, Term.ConstD, Term.ConstI, Term.ConstS, Term.Div, Term.EqB, Term.EqD, Term.EqI, Term.GeD, Term.GeI, Term.GtD, Term.GtI, Term.LeD, Term.LeI, Term.LtD, Term.LtI, Term.Mod, Term.Mul, Term.Neg, Term.NEqB, Term.NEqD, Term.NEqI, Term.NotB, Term.NotI, Term.Op, Term.OrB, Term.OrI, Term.Ref, Term.Sub, Term.Unary, Term.UnaryB, Term.UnaryI, Term.UnaryN, Term.XOrI
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <T> Taccept(TermVisitor<T> visitor)Visitor support.intcompare(Term other)booleanevalB(EvalEnv env)Evaluates this term to abooleanvalue.doubleevalD(EvalEnv env)Evaluates this term to adoublevalue.intevalI(EvalEnv env)Evaluates this term to anintvalue.StringevalS(EvalEnv env)Evaluates this term to aStringvalue.intgetRetType()Gets the term's "natural" return type.SymbolgetSymbol()VariablegetVariable()booleanisConst()intpre()StringtoString()Returns a string representation of this term which can be used for debugging.
-
-
-
Field Detail
-
symbol
protected final Symbol symbol
-
-
Constructor Detail
-
Ref
public Ref(Symbol symbol)
-
-
Method Detail
-
getSymbol
public Symbol getSymbol()
-
getVariable
public Variable getVariable()
-
getRetType
public int getRetType()
Description copied from class:TermGets the term's "natural" return type.- Specified by:
getRetTypein classTerm- Returns:
- the type, should always be one of the
TYPE_X constants defined in this class.
-
evalB
public boolean evalB(EvalEnv env)
Description copied from class:TermEvaluates this term to abooleanvalue.
-
evalI
public int evalI(EvalEnv env)
Description copied from class:TermEvaluates this term to anintvalue.
-
evalD
public double evalD(EvalEnv env)
Description copied from class:TermEvaluates this term to adoublevalue.
-
evalS
public String evalS(EvalEnv env)
Description copied from class:TermEvaluates this term to aStringvalue. The default implementation simply returns the value ofTerm.toString().
-
toString
public String toString()
Description copied from class:TermReturns a string representation of this term which can be used for debugging.
-
accept
public <T> T accept(TermVisitor<T> visitor)
Description copied from class:TermVisitor support.
-
isConst
public boolean isConst()
-
-