Package com.blackrook.expression
Interface ExpressionNode
-
- All Known Implementing Classes:
ExpressionBranch
,ExpressionDirective
,ExpressionFunction
public interface ExpressionNode
A single node in a compiled expression.- Author:
- Matthew Tropiano
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
execute(ExpressionStack stack, ExpressionVariableContext context)
Executes this node.boolean
isCollapsable()
Checks if this node is collapsable.void
writeBytes(OutputStream out)
Write value as bytes (for digest later).
-
-
-
Method Detail
-
isCollapsable
boolean isCollapsable()
Checks if this node is collapsable.- Returns:
- true if so, false if not.
-
execute
boolean execute(ExpressionStack stack, ExpressionVariableContext context)
Executes this node.- Parameters:
stack
- the stack to use.context
- the context for added variables.- Returns:
- if false, stop expression calculation, else if true, continue.
-
writeBytes
void writeBytes(OutputStream out) throws IOException
Write value as bytes (for digest later).- Parameters:
out
- the output stream.- Throws:
IOException
- on a write error.
-
-