public class PathExpanderBuilder extends Object
path expanders.
See PathExpanders for a catalog of common expanders.| Modifier and Type | Method and Description |
|---|---|
PathExpanderBuilder |
add(RelationshipType type)
Add a pair of
type and Direction.BOTH to the PathExpander configuration. |
PathExpanderBuilder |
add(RelationshipType type,
Direction direction)
Add a pair of
type and direction to the PathExpander configuration. |
static PathExpanderBuilder |
allTypes(Direction direction)
A
PathExpanderBuilder seeded with all possible types but restricted to direction. |
static <STATE> PathExpanderBuilder |
allTypesAndDirections()
A
PathExpanderBuilder that is seeded with all possible relationship types in both
directions. |
<STATE> PathExpander<STATE> |
build()
Produce a PathExpander from the configuration you have built up.
|
static PathExpanderBuilder |
empty()
A
PathExpanderBuilder that follows no relationships. |
PathExpanderBuilder |
remove(RelationshipType type)
Remove expansion of
type in any direction from the PathExpander configuration. |
public static PathExpanderBuilder empty()
PathExpanderBuilder that follows no relationships. You start with this and use
add(RelationshipType, Direction) to form a restrictive PathExpander with just a few expansion rules
in it.public static <STATE> PathExpanderBuilder allTypesAndDirections()
PathExpanderBuilder that is seeded with all possible relationship types in both
directions. You start with this and remove types to form a permissive
PathExpander with just a few exceptions in it.public static PathExpanderBuilder allTypes(Direction direction)
PathExpanderBuilder seeded with all possible types but restricted to direction. You start
with this and remove types to form a permissive PathExpander with
just a few exceptions in it.direction - The direction you want to restrict expansions topublic PathExpanderBuilder add(RelationshipType type)
type and Direction.BOTH to the PathExpander configuration.public PathExpanderBuilder add(RelationshipType type, Direction direction)
type and direction to the PathExpander configuration.public PathExpanderBuilder remove(RelationshipType type)
type in any direction from the PathExpander configuration.
Example: PathExpanderBuilder.allTypesAndDirections().remove(type).add(type, Direction.INCOMING)
would restrict the PathExpander to only follow Direction.INCOMING relationships for type while following any other relationship type in either direction.public <STATE> PathExpander<STATE> build()
Copyright © 2002–2015 The Neo4j Graph Database Project. All rights reserved.