Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Neo4j Community
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.neo4j.graphmatching
Class AbstractPatternObject<T extends PropertyContainer>

    java.lang.Object
      org.neo4j.graphmatching.AbstractPatternObject<T>

Type Parameters:
  `T` - either `Node` or `Relationship`.

Direct Known Subclasses:
  PatternNode, PatternRelationship

    public abstract class AbstractPatternObject<T extends PropertyContainer>

extends Object

The base class for `PatternNode` and `PatternRelationship`.

Field Summary
`protected String` | `label`

Method Summary
`void` | `addPropertyConstraint(String propertyKey, ValueMatcher matcher)` Add a constraint to the property with the given key on this pattern object.
`T` | `getAssociation()` Get the `Node` or `Relationship` currently associated with this pattern object.
`String` | `getLabel()` Get the label of this pattern object.
`Iterable<Map.Entry<String,Collection<ValueMatcher>>>` | `getPropertyConstraints()` Get all the constraints on the properties of this pattern object.
`void` | `setAssociation(T object)` Associate this object with a particular `Node` or `Relationship`.
`void` | `setLabel(String label)` Sets the label of this pattern object;

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### label

    protected String label

Method Detail

### addPropertyConstraint

    public void addPropertyConstraint(String propertyKey,
                                      ValueMatcher matcher)

  Add a constraint to the property with the given key on this pattern object.

  Parameters:
    `propertyKey` - the key of the property to add a constraint to.
    `matcher` - the constraint to add on the property.

### setAssociation

    public void setAssociation(T object)

  Associate this object with a particular `Node` or `Relationship`. When a pattern object is associated with an actual object it will only match that object. Set the association to `null` to remove the association.

  Parameters:
    `object` - the `Node` or `Relationship` to associate this pattern object with.

### getAssociation

    public T getAssociation()

  Get the `Node` or `Relationship` currently associated with this pattern object.

  Returns:
    the `Node` or `Relationship` associated with this pattern object.

### getPropertyConstraints

    public Iterable<Map.Entry<String,Collection<ValueMatcher>>> getPropertyConstraints()

  Get all the constraints on the properties of this pattern object.

  Returns:
    an iterable of all constrained properties with all constraints for each of them.

### getLabel

    public String getLabel()

  Get the label of this pattern object.

  Returns:
    the label of this pattern object.

### setLabel

    public void setLabel(String label)

  Sets the label of this pattern object;

  Parameters:
    `label` - the label of this pattern object;

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Neo4j Community
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

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