public class Pipe extends Object implements Analyzer
Pipe class contains a sequence of analyzers.
It follows the composite pattern to manage the analyzers. Uses the method
add(Analyzer) to add analyzers into the pipe.
analyze(Document) method is thread-safe, if all analyzers in it
are also thread-safe, which is the case of the default analyzers.| Constructor and Description |
|---|
Pipe() |
| Modifier and Type | Method and Description |
|---|---|
void |
add(Analyzer aAnalyzer)
Adds an analyzer into the pipe.
|
void |
analyze(Document document)
Analyzes part of a text or a word.
|
public void add(Analyzer aAnalyzer)
Follows the composite pattern standards.
aAnalyzer - is the analyzer to be added in the pipe.Copyright © 2012–2017 CoGrOO. All rights reserved.