Commit f112e444 authored by Lisa's avatar Lisa
Browse files

Pakabei fix and check removed

parent 0567dea9
......@@ -49,7 +49,6 @@ bool CommandLine::isSet(const QString& command)
m_index = m_commands.indexOf(actualCom);
if (m_index != -1) {
m_commands.removeAt(m_index);
return true;
}
......@@ -84,13 +83,6 @@ QStringList CommandLine::args()
return result;
}
void CommandLine::checkUnknownOptions()
{
if (!m_commands.isEmpty()) {
throw UnknownOptionException(m_commands.first());
}
}
/*
* Build our database of accepted operations and options with the right properties and associations
*/
......@@ -249,8 +241,6 @@ void PakabeiParser::parse()
if (m_freeArgs.isEmpty() && freeArgsRequired()) {
throw ExpectedArgumentsException();
}
commandLine.checkUnknownOptions();
}
/*
......
......@@ -47,13 +47,6 @@ public:
*/
QStringList args();
/**
* Checks the presence of options the parser didn't check with isSet.
* Such a presence would mean the user set something not allowed in the parser.
* @throws UnknownOptionException if an unknown option is found.
*/
void checkUnknownOptions();
private:
QStringList m_commands; /* the command line list */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment