org.neo4j.graphdb.traversal
Class InitialStateFactory.AsInitialBranchState<STATE>

java.lang.Object
  extended by org.neo4j.graphdb.traversal.InitialStateFactory.AsInitialBranchState<STATE>
All Implemented Interfaces:
InitialBranchState<STATE>, InitialStateFactory<STATE>
Enclosing interface:
InitialStateFactory<STATE>

public static class InitialStateFactory.AsInitialBranchState<STATE>
extends Object
implements InitialBranchState<STATE>

Wraps an InitialStateFactory in a InitialBranchState


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.neo4j.graphdb.traversal.InitialBranchState
InitialBranchState.Adapter<STATE>, InitialBranchState.State<STATE>
 
Nested classes/interfaces inherited from interface org.neo4j.graphdb.traversal.InitialStateFactory
InitialStateFactory.AsInitialBranchState<STATE>
 
Field Summary
 
Fields inherited from interface org.neo4j.graphdb.traversal.InitialBranchState
NO_STATE
 
Constructor Summary
InitialStateFactory.AsInitialBranchState(InitialStateFactory<STATE> factory)
           
 
Method Summary
 STATE initialState(Path path)
          Returns an initial state for a Path.
 InitialBranchState<STATE> reverse()
          Creates a version of this state factory which produces reversed initial state, used in bidirectional traversals.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InitialStateFactory.AsInitialBranchState

public InitialStateFactory.AsInitialBranchState(InitialStateFactory<STATE> factory)
Method Detail

reverse

public InitialBranchState<STATE> reverse()
Description copied from interface: InitialBranchState
Creates a version of this state factory which produces reversed initial state, used in bidirectional traversals.

Specified by:
reverse in interface InitialBranchState<STATE>
Returns:
an instance which produces reversed initial state.

initialState

public STATE initialState(Path path)
Description copied from interface: InitialStateFactory
Returns an initial state for a Path. All paths entering this method are start paths(es) of a traversal. State is passed down along traversal branches as the traversal progresses and can be changed at any point by a PathExpander to becomes the new state from that point in that branch and downwards.

Specified by:
initialState in interface InitialStateFactory<STATE>
Parameters:
path - the start branch to return the initial state for.
Returns:
an initial state for the traversal branch.


Copyright © 2002-2013 The Neo4j Graph Database Project. All Rights Reserved.