c++/parameter-lister/info/globalcode/parameterLister/OutputModule.cpp
author František Kučera <franta-hg@frantovo.cz>
Tue, 05 May 2015 22:46:40 +0200
changeset 20 0684883953ba
parent 19 48a3c9c50937
child 28 bfef9f34e438
permissions -rw-r--r--
TODO: escapeValue()
franta-hg@7
     1
#include "OutputModule.h"
franta-hg@11
     2
#include "terminalCodes/TerminalCodes.h"
franta-hg@7
     3
franta-hg@8
     4
namespace info {
franta-hg@8
     5
namespace globalcode {
franta-hg@8
     6
namespace parameterLister {
franta-hg@8
     7
franta-hg@19
     8
using namespace std;
franta-hg@11
     9
franta-hg@19
    10
int OutputModule::process(ostream &output, string &command, vector<std::string> &args) {
franta-hg@11
    11
franta-hg@18
    12
	for (int i = 0; i < args.size(); i++) {
franta-hg@18
    13
		string s = args[i];
franta-hg@20
    14
		output << i + 1 << ":" << s.length() << " = \"" << escapeValue(s, true) << "\"" << endl;
franta-hg@18
    15
	}
franta-hg@14
    16
franta-hg@16
    17
	return 0;
franta-hg@8
    18
}
franta-hg@8
    19
franta-hg@20
    20
string OutputModule::escapeValue(string value, bool colorize) {
franta-hg@20
    21
	return value;
franta-hg@20
    22
}
franta-hg@9
    23
franta-hg@9
    24
}
franta-hg@9
    25
}
franta-hg@9
    26
}
franta-hg@9
    27