Examples of forNodes()


Examples of org.neo4j.graphdb.index.IndexManager.forNodes()

    private void clearIndex(Map<String, Object> result) {
        IndexManager indexManager = graph.index();
        result.put("node-indexes", Arrays.asList(indexManager.nodeIndexNames()));
        result.put("relationship-indexes", Arrays.asList(indexManager.relationshipIndexNames()));
        for (String ix : indexManager.nodeIndexNames()) {
            indexManager.forNodes(ix).delete();
        }
        for (String ix : indexManager.relationshipIndexNames()) {
            indexManager.forRelationships(ix).delete();
        }
    }
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

    }

    private void removeFromIndexes(Node node) {
        final RestIndexManager indexManager = index();
        for (String indexName : indexManager.nodeIndexNames()) {
            indexManager.forNodes(indexName).remove(node);
        }
    }

    private void removeFromIndexes(Relationship relationship) {
        final RestIndexManager indexManager = index();
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

    }

    private void removeFromIndexes(Node node) {
        final RestIndexManager indexManager = index();
        for (String indexName : indexManager.nodeIndexNames()) {
            indexManager.forNodes(indexName).remove(node);
        }
    }

    private void removeFromIndexes(Relationship relationship) {
        final RestIndexManager indexManager = index();
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

  }
 
  @Test
  public void testIndexForNodes(){
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
         Index<Node> testIndex = index.forNodes("indexName");
         assertTrue(index.existsForNodes("indexName"));
  }
 
  @Test
  public void testGetIndexForNodes(){
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

  }
 
  @Test
  public void testGetIndexForNodes(){
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
      Index<Node> testIndex = index.forNodes("indexName");
      Assert.assertEquals(testIndex.getName(), this.restAPI.getIndex("indexName").getName());     
  }
 
  @Test
  public void testCreateRestAPIIndexForNodes(){   
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

 
  @Test
  public void testForDoubleCreatedIndexForNodesWithSameParamsWithoutFullText() {
    this.restAPI.createIndex(Node.class, "indexName", LuceneIndexImplementation.EXACT_CONFIG);   
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
         Index<Node> testIndex = index.forNodes("indexName");      
  }
 
  @Test (expected = IllegalArgumentException.class)
  public void testForDoubleCreatedIndexForNodesWithEmptyParams() {
    this.restAPI.createIndex(Node.class, "indexName", LuceneIndexImplementation.FULLTEXT_CONFIG);
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

 
  @Test (expected = IllegalArgumentException.class)
  public void testForDoubleCreatedIndexForNodesWithEmptyParams() {
    this.restAPI.createIndex(Node.class, "indexName", LuceneIndexImplementation.FULLTEXT_CONFIG);
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
         Index<Node> testIndex = index.forNodes("indexName", new HashMap<String, String>());      
  }
 
  @Test (expected = IllegalArgumentException.class)
  public void testForDoubleCreatedIndexForNodesWithEmptyParamsReversed() {
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

  }
 
  @Test (expected = IllegalArgumentException.class)
  public void testForDoubleCreatedIndexForNodesWithEmptyParamsReversed() {
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
         Index<Node> testIndex = index.forNodes("indexName", new HashMap<String, String>());  
    this.restAPI.createIndex(Node.class, "indexName", LuceneIndexImplementation.FULLTEXT_CONFIG);      
  }
 
  @Test (expected = IllegalArgumentException.class)
  public void testForDoubleCreatedIndexForNodesWithDifferentParamsViaREST() {
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

  public void testForDoubleCreatedIndexForNodesWithDifferentParams() {
    this.restAPI.createIndex(Node.class, "indexName", LuceneIndexImplementation.FULLTEXT_CONFIG);
    HashMap<String, String> config = new HashMap<String, String>();
    config.put("test", "value");
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
         Index<Node> testIndex = index.forNodes("indexName", config);  
  }
 
  @Test (expected = IllegalArgumentException.class)
  public void testForDoubleCreatedIndexForNodesWithDifferentParamsReversed() {   
    HashMap<String, String> config = new HashMap<String, String>();
View Full Code Here

Examples of org.neo4j.rest.graphdb.index.RestIndexManager.forNodes()

  @Test (expected = IllegalArgumentException.class)
  public void testForDoubleCreatedIndexForNodesWithDifferentParamsReversed() {   
    HashMap<String, String> config = new HashMap<String, String>();
    config.put("test", "value");
    RestIndexManager index = (RestIndexManager) getRestGraphDb().index();
         Index<Node> testIndex = index.forNodes("indexName", config)
         this.restAPI.createIndex(Node.class, "indexName", LuceneIndexImplementation.FULLTEXT_CONFIG);
  }
 
  @Test
  public void testGetIndexByIndexForNodesCreationViaRestAPI(){
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.