Neo4j Community

org.neo4j.graphmatching
Class PatternElement

java.lang.Object
  extended by org.neo4j.graphmatching.PatternElement

public class PatternElement
extends Object

Represents a part of a match. It holds the matching Node, its corresponsing PatternNode in the client-supplied pattern as well as the last Relationship and PatternRelationship to get there.


Method Summary
 PatternRelationship getFromPatternRelationship()
          Returns the PatternRelationship corresponding to the matching Relationship.
 Relationship getFromRelationship()
          Returns the Relationship traversed to get to the Node returned from getNode().
 Node getNode()
          Returns the matching Node which is just one part of the whole match.
 PatternNode getPatternNode()
          Returns the PatternNode corresponding to the matching Node.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getPatternNode

public PatternNode getPatternNode()
Returns the PatternNode corresponding to the matching Node.

Returns:
the PatternNode corresponsing to matching Node.

getNode

public Node getNode()
Returns the matching Node which is just one part of the whole match.

Returns:
the matching Node which is just one part of the whole match.

toString

public String toString()
Overrides:
toString in class Object

getFromPatternRelationship

public PatternRelationship getFromPatternRelationship()
Returns the PatternRelationship corresponding to the matching Relationship.

Returns:
the PatternRelationship corresponsing to matching Relationship.

getFromRelationship

public Relationship getFromRelationship()
Returns the Relationship traversed to get to the Node returned from getNode().

Returns:
the Relationship traversed to get to this node.

Neo4j Community

Copyright © 2011 The Neo4j Graph Database Project. All Rights Reserved.