public class NestedBlockBuilderImpl extends java.lang.Object implements NestedBlockBuilder
RexNode
expressions.Modifier and Type | Field and Description |
---|---|
private java.util.List<BlockBuilder> |
blocks |
private java.util.List<java.util.Map<RexNode,java.lang.Boolean>> |
nullables |
Constructor and Description |
---|
NestedBlockBuilderImpl(BlockBuilder block)
Constructs nested block builders starting of a given code block.
|
Modifier and Type | Method and Description |
---|---|
BlockBuilder |
currentBlock()
Returns the current code block
|
java.util.Map<RexNode,java.lang.Boolean> |
currentNullables()
Returns the current nullability state of rex nodes.
|
void |
exitBlock()
Leaves the current code block.
|
BlockBuilder |
nestBlock()
Starts nested code block.
|
void |
nestBlock(BlockBuilder block)
Uses given block as the new code context.
|
void |
nestBlock(BlockBuilder block,
java.util.Map<RexNode,java.lang.Boolean> nullables)
Uses given block as the new code context and the map of nullability.
|
private final java.util.List<BlockBuilder> blocks
private final java.util.List<java.util.Map<RexNode,java.lang.Boolean>> nullables
public NestedBlockBuilderImpl(BlockBuilder block)
block
- root code blockpublic final BlockBuilder nestBlock()
nestBlock
in interface NestedBlockBuilder
public final void nestBlock(BlockBuilder block)
exitBlock()
call.nestBlock
in interface NestedBlockBuilder
block
- new code blockexitBlock()
public final void nestBlock(BlockBuilder block, java.util.Map<RexNode,java.lang.Boolean> nullables)
exitBlock()
call.nestBlock
in interface NestedBlockBuilder
block
- new code blocknullables
- map of expression to its nullability stateexitBlock()
public final BlockBuilder currentBlock()
currentBlock
in interface NestedBlockBuilder
public final java.util.Map<RexNode,java.lang.Boolean> currentNullables()
currentNullables
in interface NestedBlockBuilder
public final void exitBlock()
exitBlock
in interface NestedBlockBuilder
nestBlock()
Copyright © 2012–2019 The Apache Software Foundation. All rights reserved.