Package org.project.service
Class ProcessorFactory
java.lang.Object
org.project.service.ProcessorFactory
Factory to get the right InputProcessor for a given type.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic InputProcessorgetProcessor(String type) Get processor for the given type.
-
Constructor Details
-
ProcessorFactory
public ProcessorFactory()
-
-
Method Details
-
getProcessor
Get processor for the given type.- Parameters:
type- input type (e.g. "text")- Returns:
- InputProcessor for the type
- Throws:
IllegalArgumentException- if type is not supported
-