Package org.sonar.javascript.se.sv
Class LiteralSymbolicValue
- java.lang.Object
-
- org.sonar.javascript.se.sv.LiteralSymbolicValue
-
- All Implemented Interfaces:
SymbolicValue
public class LiteralSymbolicValue extends Object implements SymbolicValue
This class represents symbolic value for literal (string, number and boolean). Current implementation provides only truthy/falsy constraint for this symbolic value, thus we are not able to process numeric constraints.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ConstraintbaseConstraint(ProgramState state)Optional<ProgramState>constrainDependencies(ProgramState state, Constraint constraint)static SymbolicValueget(LiteralTree literal)LiteralTreegetLiteral()StringtoString()
-
-
-
Method Detail
-
get
public static SymbolicValue get(LiteralTree literal)
-
getLiteral
public LiteralTree getLiteral()
-
constrainDependencies
public Optional<ProgramState> constrainDependencies(ProgramState state, Constraint constraint)
- Specified by:
constrainDependenciesin interfaceSymbolicValue
-
baseConstraint
public Constraint baseConstraint(ProgramState state)
- Specified by:
baseConstraintin interfaceSymbolicValue
-
-