c++/parameter-lister/info/globalcode/parameterLister/TerminalOutputModule.cpp
author František Kučera <franta-hg@frantovo.cz>
Mon, 04 May 2015 00:12:33 +0200
changeset 11 870b868b6b57
parent 9 598a575ae57f
child 12 fde958908539
permissions -rw-r--r--
move formatting logic to output modules
     1 #include "TerminalOutputModule.h"
     2 
     3 namespace info {
     4 namespace globalcode {
     5 namespace parameterLister {
     6 
     7 TerminalOutputModule::TerminalOutputModule() {
     8 }
     9 
    10 TerminalOutputModule::TerminalOutputModule(const TerminalOutputModule& orig) {
    11 }
    12 
    13 TerminalOutputModule::~TerminalOutputModule() {
    14 }
    15 
    16 void TerminalOutputModule::process(std::ostream &output, std::string &command, std::vector<std::string> &args) {
    17 	using namespace std;
    18 	output << "<terminalOutputModule>" << endl;
    19 	
    20 	for (int i = 0; i < args.size(); i++) {
    21 		string s = args[i];
    22 		cout << i + 1 << ":" << s.length() << " = \"" << s << "\"" << endl;
    23 	}
    24 	
    25 	output << "</terminalOutputModule>" << endl;
    26 }
    27 
    28 }
    29 }
    30 }
    31