Added (default == false) verbose keyword for the parseFile() method

This commit is contained in:
Joakim Hove
2013-10-01 16:05:01 +02:00
parent b938057dbd
commit 94250f6e03

View File

@@ -83,6 +83,7 @@ namespace Opm {
void Parser::parseFile(DeckPtr deck, const boost::filesystem::path& file, const boost::filesystem::path& rootPath, bool parseStrict) const {
bool verbose = false;
std::ifstream inputstream;
inputstream.open(file.string().c_str());
@@ -98,8 +99,14 @@ namespace Opm {
if (includeFile.is_relative())
includeFile = rootPath / includeFile;
if (verbose)
std::cout << rawKeyword->getKeywordName() << " " << includeFile << std::endl;
parseFile(deck, includeFile, rootPath , parseStrict);
} else {
if (verbose)
std::cout << rawKeyword->getKeywordName() << std::endl;
if (hasKeyword(rawKeyword->getKeywordName())) {
ParserKeywordConstPtr parserKeyword = m_parserKeywords.at(rawKeyword->getKeywordName());
DeckKeywordConstPtr deckKeyword = parserKeyword->parse(rawKeyword);