Question: You are to create a C++ program that opens an input file, reads and process the data in that file, and then writes the (possibly

You are to create a C++ program that opens an input file, reads and process the data in that file, and then writes the (possibly modified) data to a new output file. Your program should:

Accept arguments that are presented on the command line (see Usage box below).

Use the Templatized C++ Command Line Parser for argument processing (See the Templatized C++ Command Line Parser below). Illegal or missing options should be handled properly.

Store the parsing results into a C++ STL map. The map file must be indexed by a C++ enumerated list (enum) and should hold strings for values.

Within your code, you must query your map to get the values of the parsed command line arguments. Finally, your program must present the correct behavior.

Your program should open the input file for reading and the output file for writing. It should copy all data from the input file to the output file while optionally converting case as directed by the command line arguments. -u and -l are mutually exclusive. Only one may be given but neither is required. If the output file is not specified (it is optional), you should write to a file with the default name of "output.txt". Deliverables You must submit your homework through ELearning. You must include your .cc files and any header files you create (not TCLAP header files)

Templatized C++ Command Line Parser It is often the case that you will want to use third party code. For Program 2, we will use a library from a well-known open source repository. Specifically, we will utilize the Templatized C++ Command Line Parser (TCLAP). TCLAP is a SourceForge project. SourceForge is a web-based source code repository. It acts as a centralized location for software developers to control and manage free and open-source software development. All information about the parser may be found at:

http://tclap.sourceforge.net

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!