Package com.github.krukow.clj_lang

Examples of com.github.krukow.clj_lang.PersistentHATTrie


    trie = (PersistentHATTrie<Integer>) trie.addMember("forks",9);
    return trie;
  }
  @Test
  public final void testSmallTrie() {
    PersistentHATTrie trie = createTrie();
    assertEquals(10, trie.count());
   
    assertEquals(0, trie.getMember("we"));
    assertEquals(1, trie.getMember("were"));
    assertEquals(2, trie.getMember("went"));
    assertEquals(3, trie.getMember("west"));
    assertEquals(4, trie.getMember("water"));
    assertEquals(5, trie.getMember("western"));
    assertEquals(6, trie.getMember("tri"));
    assertEquals(7, trie.getMember("fork"));
    assertEquals(8, trie.getMember("trifork"));
    assertEquals(9, trie.getMember("forks"));   
  }
View Full Code Here


    assertEquals(9, trie.getMember("forks"));   
  }
 
  @Test
  public final void doesNotContainNotAdded() {
    PersistentHATTrie trie = createTrie();
    assertNull(trie.getMember("wes"));
    assertNull(trie.getMember("w"));
    assertNull(trie.getMember("wents"));
    assertNull(trie.getMember("westee"));
    assertNull(trie.getMember("tris"));
    assertNull(trie.getMember("sfork"));
    assertNull(trie.getMember("tri2fork"));
    assertNull(trie.getMember("forksa"));   
  }
View Full Code Here

TOP

Related Classes of com.github.krukow.clj_lang.PersistentHATTrie

Copyright © 2018 www.massapicom. 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.