Commit a3cc314e authored by Daniele Kruse's avatar Daniele Kruse
Browse files

Added the postfix :base64 for cmdline options that have an encoded value

parent 628fb447
This diff is collapsed.
......@@ -154,30 +154,28 @@ protected:
*
* @param optionShortName The short name of the required option
* @param optionLongName The long name of the required option
* @param encoded True if the argument is encoded, false otherwise
* @param required True if the option is required, false otherwise
* @param useDefaultIfMissing True if the default value (next parameter) is to be used if option is missing from cmdline, false otherwise
* @param default Value of the default in case option is missing from cmdline (and useDefaultIfMissing is true)
* @return the option value (empty if absent)
*/
optional<std::string> getOptionStringValue(const std::string& optionShortName, const std::string& optionLongName,
const bool encoded, const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="-");
const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="-");
optional<uint64_t> getOptionUint64Value(const std::string& optionShortName, const std::string& optionLongName,
const bool encoded, const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="0");
const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="0");
optional<bool> getOptionBoolValue(const std::string& optionShortName, const std::string& optionLongName,
const bool encoded, const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="false");
const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="false");
optional<time_t> getOptionTimeValue(const std::string& optionShortName, const std::string& optionLongName,
const bool encoded, const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="01/01/1970");
const bool required, const bool useDefaultIfMissing, const std::string& defaultValue="01/01/1970");
/**
* Returns the string/numerical/boolean value of the specified option
*
* @param optionShortName The short name of the required option
* @param optionLongName The long name of the required option
* @param encoded True if the argument is encoded, false otherwise
* @return the option value (empty if absent)
*/
std::string getOption(const std::string& optionShortName, const std::string& optionLongName, const bool encoded);
std::string getOption(const std::string& optionShortName, const std::string& optionLongName);
/**
* Given the command line string vector it returns true if the specified option is present, false otherwise
......
Supports Markdown
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