- Timestamp:
- 10/15/11 01:41:55 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/EventBenchCore/src/de/ugoe/cs/eventbench/models/Trie.java
r251 r258 85 85 */ 86 86 public void train(List<T> sequence, int maxOrder) { 87 if ( maxOrder<1) {87 if (maxOrder < 1) { 88 88 return; 89 89 } … … 400 400 return rootNode.getNumLeafs(); 401 401 } 402 403 /** 404 * <p> 405 * Updates the list of known symbols by replacing it with all symbols that 406 * are found in the child nodes of the root node. This should be the same as 407 * all symbols that are contained in the trie. 408 * </p> 409 */ 410 public void updateKnownSymbols() { 411 knownSymbols = new HashSet<T>(); 412 for (TrieNode<T> node : rootNode.getChildren()) { 413 knownSymbols.add(node.getSymbol()); 414 } 415 } 402 416 }
Note: See TracChangeset
for help on using the changeset viewer.