Prev |  | Next

## 3.6. Traversal

Traversing a graph means visiting its nodes, following relationships according to some rules. In most cases only a subgraph is visited, as you already know where in the graph the interesting nodes and relationships are found.

Cypher provides a declarative way to query the graph powered by traversals and other techniques. See Part III, “Cypher Query Language” for more information.

Neo4j comes with a callback based traversal API which lets you specify the traversal rules. At a basic level there’s a choice between traversing breadth- or depth-first.

For an in-depth introduction to the traversal framework, see Chapter 34, The Traversal Framework. For Java code examples see Section 33.7, “Traversal”.

Copyright © 2014 Neo Technology

Prev | Up | Next
| Home |