net.sf.eos.trie
Class AbstractTrieLoader<K,V>
java.lang.Object
net.sf.eos.trie.AbstractTrieLoader<K,V>
- All Implemented Interfaces:
- TrieLoader<K,V>
- Direct Known Subclasses:
- XmlTrieLoader
public abstract class AbstractTrieLoader<K,V>
- extends Object
- implements TrieLoader<K,V>
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TRIE_LOADER_IMPL_CONFIG_NAME
@ConfigurationKey(type=CLASSNAME,
description="Configuration key of the trie loader factory.")
public static final String TRIE_LOADER_IMPL_CONFIG_NAME
- See Also:
- Constant Field Values
AbstractTrieLoader
public AbstractTrieLoader()
newInstance
@FactoryMethod(key="net.sf.eos.trie.AbstractTrieLoader.impl",
implementation=XmlTrieLoader.class)
public static final TrieLoader newInstance()
throws TokenizerException
- Default
TrieLoader
is XmlTrieLoader
.
- Returns:
- a loader
- Throws:
TokenizerException
newInstance
@FactoryMethod(key="net.sf.eos.trie.AbstractTrieLoader.impl",
implementation=XmlTrieLoader.class)
public static final TrieLoader newInstance(Configuration config)
throws TokenizerException
- Throws:
TokenizerException
loadTrie
public abstract void loadTrie(InputStream trieData,
Trie<K,V> trie)
throws Exception
- Description copied from interface:
TrieLoader
- Creates a <
Trie
from the InputStream
.
- Specified by:
loadTrie
in interface TrieLoader<K,V>
- Parameters:
trieData
- stream pointing to the trie structure data.trie
- the trie to fill with the trieData
- Throws:
Exception
- if the builder is unable to create the trie.
Copyright © 2008. All Rights Reserved.