|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectopennlp.tools.cmdline.StreamFactoryRegistry
public final class StreamFactoryRegistry
Registry for object stream factories.
| Field Summary | |
|---|---|
static String |
DEFAULT_FORMAT
|
| Method Summary | ||
|---|---|---|
static
|
getFactories(Class<T> sampleClass)
Returns all factories which produce objects of sampleClass class. |
|
static
|
getFactory(Class<T> sampleClass,
String formatName)
Returns a factory which reads format named formatName and instantiates streams producing objects of sampleClass class. |
|
static boolean |
registerFactory(Class sampleClass,
String formatName,
ObjectStreamFactory factory)
Registers factory which reads format named formatName and instantiates streams producing objects of sampleClass class. |
|
static void |
unregisterFactory(Class sampleClass,
String formatName)
Unregisters a factory which reads format named formatName and instantiates streams producing objects of sampleClass class. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String DEFAULT_FORMAT
| Method Detail |
|---|
public static boolean registerFactory(Class sampleClass,
String formatName,
ObjectStreamFactory factory)
sampleClass - class of the objects, produced by the streams instantiated by the factoryformatName - name of the formatfactory - instance of the factory
public static void unregisterFactory(Class sampleClass,
String formatName)
sampleClass - class of the objects, produced by the streams instantiated by the factoryformatName - name of the formatpublic static <T> Map<String,ObjectStreamFactory<T>> getFactories(Class<T> sampleClass)
sampleClass - class of the objects, produced by the streams instantiated by the factory
public static <T> ObjectStreamFactory<T> getFactory(Class<T> sampleClass,
String formatName)
sampleClass - class of the objects, produced by the streams instantiated by the factoryformatName - name of the format, if null, assumes OpenNLP format
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||