public interface TestPState
extends java.io.Closeable
Block.localSelect(java.lang.String, com.rpl.rama.Path)
and Block.localTransform(java.lang.String, com.rpl.rama.Path)
.
This can be used in unit tests of snippets of dataflow code, or it can be used to explore PStates and paths.
This object should be closed when no longer needed to clean up its resources.Modifier and Type | Method and Description |
---|---|
static TestPState |
create(java.lang.Class schema)
Creates a TestPState with the given schema.
|
static TestPState |
create(PState.Schema schema)
Creates a TestPState with the given schema.
|
<T> java.util.List<T> |
select(Path path)
Queries PState with
Path . |
<T> T |
selectOne(Path path)
Queries PState with
Path that must navigate to exactly one value. |
void |
transform(Path path)
Transforms PState with
Path . |
static TestPState create(PState.Schema schema)
static TestPState create(java.lang.Class schema)
<T> java.util.List<T> select(Path path)
Path
.T
- Type of navigated valuespath
- Query path<T> T selectOne(Path path)
Path
that must navigate to exactly one value.T
- Type of navigated valuepath
- Query pathvoid transform(Path path)
Path
.path
- transform path