The Neo4j graph pattern matching component

This component provides means for searching for patterns in a Neo4j Graph Database.

The pattern matching is done by first defining a graph pattern and then searching for matching occurrences of that pattern in the graph around a given anchor node.

Introduction to the API

For complete API reference, please refer to the JavaDoc pages.

A graph matching pattern is made up of two main object types, the PatternNode and the PatternRelationship. PatternNodes and PatternRelationships can be associated with actual Nodes and Relationships respectively, or can be restricted by a set of property constraints. Associating a PatternNode with a Node or a PatternRelationship with a Relatoonship will force that PatternNode or PatternRelationship to only match the Node or Relationship it was associated with. Adding constraints on properties will restrict that PatternNode or PatternRelationship to only match a Node or Relationship where the property with the given name matches the defined restriction.

Examples

See TestSiteIndexExamples.java for examples.