private void removeFromIndexes(Relationship relationship) {
     final IndexManager indexManager = delegate.index();
     for (String indexName : indexManager.relationshipIndexNames()) {
         RelationshipIndex relationshipIndex = indexManager.forRelationships(indexName);
         if (relationshipIndex.isWriteable()) relationshipIndex.remove(relationship);
     }
 }
Ejemplo n.º 2
0
 public void removeFromRelationshipIndexNoKeyValue(String indexName, long id) {
   RelationshipIndex index = graphDb.index().forRelationships(indexName);
   Transaction tx = graphDb.beginTx();
   try {
     index.remove(graphDb.getRelationshipById(id));
     tx.success();
   } finally {
     tx.finish();
   }
 }