public abstract static class UniqueFactory.UniqueRelationshipFactory extends UniqueFactory<Relationship>
UniqueFactory
for Relationship
.UniqueFactory.UniqueNodeFactory, UniqueFactory.UniqueRelationshipFactory
Constructor and Description |
---|
UniqueFactory.UniqueRelationshipFactory(GraphDatabaseService graphdb,
String index)
Create a new
UniqueFactory for relationships. |
UniqueFactory.UniqueRelationshipFactory(Index<Relationship> index)
Create a new
UniqueFactory for relationships. |
Modifier and Type | Method and Description |
---|---|
protected void |
delete(Relationship relationship)
Default implementation of
UniqueFactory.delete(PropertyContainer) . |
protected void |
initialize(Relationship relationship,
Map<String,Object> properties)
Default implementation of
UniqueFactory.initialize(PropertyContainer, Map) , does nothing
for Relationships . |
create, getOrCreate, graphDatabase, index
public UniqueFactory.UniqueRelationshipFactory(Index<Relationship> index)
UniqueFactory
for relationships.index
- the index to store entities uniquely in.public UniqueFactory.UniqueRelationshipFactory(GraphDatabaseService graphdb, String index)
UniqueFactory
for relationships.graphdb
- the graph database to get the index from.index
- the name of the index to store entities uniquely in.protected void initialize(Relationship relationship, Map<String,Object> properties)
UniqueFactory.initialize(PropertyContainer, Map)
, does nothing
for Relationships
. Override to perform some action with the guarantee that this method
is only invoked for the transaction that succeeded in creating the Relationship
.initialize
in class UniqueFactory<Relationship>
relationship
- the created entity to initialize.properties
- the properties that this entity was indexed uniquely with.UniqueFactory.initialize(PropertyContainer, Map)
,
UniqueFactory.create(Map)
protected void delete(Relationship relationship)
UniqueFactory.delete(PropertyContainer)
. Invokes
Relationship.delete()
.delete
in class UniqueFactory<Relationship>
relationship
- the entity that was created but was not added to the index.UniqueFactory.delete(PropertyContainer)
Copyright © 2002-2013 The Neo4j Graph Database Project. All Rights Reserved.