Question
1) Reader: The system will accept a list of sentences in the form of a .txt file, or from the console. 2) Shifter: Given a
1) Reader: The system will accept a list of sentences in the form of a .txt file, or from the console. 2) Shifter: Given a set of sentences, the system will circularly shift and output all lines by repeatedly removing the first word and appending it at the end of the line, in the form of a .txt file, or from the console. 3) Sorter: Given a set of sentences, the system will then output all lines in alphabetical order, in the form of a new .txt file, or to the console. 4) StopwordRemover: Given a set of sentences, the system will filter out stop words within them, and output the filtered, unique, sentences in the form of a .txt file, or from the console. The stop words are defined within a configuration file. 5) Writer: Given a set of sentences, the system will output them in the form of a .txt file, or from the console. 6) Searcher: Given a keyword and a set of input sentences, the system will output the sentences with the keyword, and the keyword is highlighted. Each of these components should be an independent class/component, and the user can run them in any order. The system should support the following user scenarios by running these components in a proper order. QuickSearch: Given a set of sentences, the user can search if a keyword can be found. That is, the user enters a keyword, the system will return all the sentences containing the keyword both in the original sentences, and in the circular shifted sentences in alphabetic order in the console, and the keyword will be highlighted. If the keyword is not contained in any sentences previously entered, the system will return ``[keyword] not found. All the functional modules, Reader, Shifter, Sorter, Filter, Writer, and Searcher should all be implemented as subclasses of Filter. The Filter, Pipe, Pipeline, and Controller classes are provided and do not need to be changed.
Using standard input/output as Pipes. Create a separate project (component) for each of the function modules above, so that each can be executed independently as a component. When running your program, the user should be able to choose to run these components in different orders.
/** * Reads from it's pipe * @return * athrows EOFException / public String read() throws EOFException \{ return in.read(); \}Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started