@Test public void testShouldFindStrings() throws Exception { final PrefixTree tree = createTestTree(); assertFalse(tree.containsString("t")); assertFalse(tree.containsString("te")); assertTrue(tree.containsString("ted")); assertTrue(tree.containsString("ten")); assertTrue(tree.containsString("tea")); assertFalse(tree.containsString("teak")); assertTrue(tree.containsString("to")); }
public boolean containsString(@Nonnull String s) { return root.containsString(s, 0); }
PrefixTree { public boolean containsString(@Nonnull String s) { return root.containsString(s, 0); } }
PrefixTree { public boolean containsString(@Nonnull String s) { return root.containsString(s, 0); } PrefixTree(); }
PrefixTree { public boolean containsString(@Nonnull String s) { return root.containsString(s, 0); } PrefixTree(); void addString(@Nonnull String s); boolean containsString(@Nonnull String s); @Nonnull PrefixTreeNode getRoot(); }
PrefixTree { public boolean containsString(@Nonnull String s) { return root.containsString(s, 0); } PrefixTree(); void addString(@Nonnull String s); boolean containsString(@Nonnull String s); @Nonnull PrefixTreeNode getRoot();  }