Package com.schibsted.spt.data.jslt.impl
Class IfExpression
- java.lang.Object
-
- com.schibsted.spt.data.jslt.impl.AbstractNode
-
- com.schibsted.spt.data.jslt.impl.IfExpression
-
- All Implemented Interfaces:
ExpressionNode
public class IfExpression extends AbstractNode
-
-
Field Summary
Fields Modifier and Type Field Description private LetExpression[]
elselets
private ExpressionNode
orelse
private ExpressionNode
test
private ExpressionNode
then
private LetExpression[]
thenlets
-
Fields inherited from class com.schibsted.spt.data.jslt.impl.AbstractNode
location
-
-
Constructor Summary
Constructors Constructor Description IfExpression(ExpressionNode test, LetExpression[] thenlets, ExpressionNode then, LetExpression[] elselets, ExpressionNode orelse, Location location)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.fasterxml.jackson.databind.JsonNode
apply(Scope scope, com.fasterxml.jackson.databind.JsonNode input)
void
computeMatchContexts(DotExpression parent)
void
dump(int level)
java.util.List<ExpressionNode>
getChildren()
ExpressionNode
optimize()
void
prepare(PreparationContext ctx)
-
Methods inherited from class com.schibsted.spt.data.jslt.impl.AbstractNode
getLocation
-
-
-
-
Field Detail
-
test
private ExpressionNode test
-
thenlets
private LetExpression[] thenlets
-
then
private ExpressionNode then
-
elselets
private LetExpression[] elselets
-
orelse
private ExpressionNode orelse
-
-
Constructor Detail
-
IfExpression
public IfExpression(ExpressionNode test, LetExpression[] thenlets, ExpressionNode then, LetExpression[] elselets, ExpressionNode orelse, Location location)
-
-
Method Detail
-
apply
public com.fasterxml.jackson.databind.JsonNode apply(Scope scope, com.fasterxml.jackson.databind.JsonNode input)
-
computeMatchContexts
public void computeMatchContexts(DotExpression parent)
- Specified by:
computeMatchContexts
in interfaceExpressionNode
- Overrides:
computeMatchContexts
in classAbstractNode
-
optimize
public ExpressionNode optimize()
- Specified by:
optimize
in interfaceExpressionNode
- Overrides:
optimize
in classAbstractNode
-
prepare
public void prepare(PreparationContext ctx)
- Specified by:
prepare
in interfaceExpressionNode
- Overrides:
prepare
in classAbstractNode
-
getChildren
public java.util.List<ExpressionNode> getChildren()
- Specified by:
getChildren
in interfaceExpressionNode
- Overrides:
getChildren
in classAbstractNode
-
dump
public void dump(int level)
- Specified by:
dump
in interfaceExpressionNode
- Overrides:
dump
in classAbstractNode
-
-