Commit 23802ea1232f71634eaac8368be3fbc26533b24c

Authored by Henry Fredrick Schreiner
1 parent d3c3a4c5

Fix some text from last PR

Showing 1 changed file with 8 additions and 8 deletions
include/CLI/Validators.hpp
@@ -151,7 +151,7 @@ struct NonexistentPathValidator : public Validator { @@ -151,7 +151,7 @@ struct NonexistentPathValidator : public Validator {
151 } 151 }
152 }; 152 };
153 153
154 -/// validate the given string is a legal ipv4 address 154 +/// Validate the given string is a legal ipv4 address
155 struct IPV4Validator : public Validator { 155 struct IPV4Validator : public Validator {
156 IPV4Validator() { 156 IPV4Validator() {
157 tname = "IPV4"; 157 tname = "IPV4";
@@ -176,10 +176,10 @@ struct IPV4Validator : public Validator { @@ -176,10 +176,10 @@ struct IPV4Validator : public Validator {
176 } 176 }
177 }; 177 };
178 178
179 -/// validate the argument is a number and equal greater then 0 179 +/// Validate the argument is a number and equal greater then 0
180 struct PositiveNumber : public Validator { 180 struct PositiveNumber : public Validator {
181 PositiveNumber() { 181 PositiveNumber() {
182 - tname = "positive number"; 182 + tname = "POSITIVE";
183 func = [](const std::string &number_str) { 183 func = [](const std::string &number_str) {
184 int number; 184 int number;
185 if(!detail::lexical_cast(number_str, number)) { 185 if(!detail::lexical_cast(number_str, number)) {
@@ -209,13 +209,13 @@ const detail::ExistingPathValidator ExistingPath; @@ -209,13 +209,13 @@ const detail::ExistingPathValidator ExistingPath;
209 /// Check for an non-existing path 209 /// Check for an non-existing path
210 const detail::NonexistentPathValidator NonexistentPath; 210 const detail::NonexistentPathValidator NonexistentPath;
211 211
212 -/// Check for an existing path 212 +/// Check for an IP4 address
213 const detail::IPV4Validator ValidIPV4; 213 const detail::IPV4Validator ValidIPV4;
214 214
215 -/// Check for an non-existing path 215 +/// Check for a positive number
216 const detail::PositiveNumber PositiveNumber; 216 const detail::PositiveNumber PositiveNumber;
217 217
218 -/// Produce a range (factory). Min and max are inclusive. 218 +/// Produce a range (factory). Min and max are inclusive.
219 struct Range : public Validator { 219 struct Range : public Validator {
220 /// This produces a range with min and max inclusive. 220 /// This produces a range with min and max inclusive.
221 /// 221 ///
@@ -241,10 +241,10 @@ struct Range : public Validator { @@ -241,10 +241,10 @@ struct Range : public Validator {
241 }; 241 };
242 242
243 namespace detail { 243 namespace detail {
244 -/// split a string into a program name and command line arguments 244 +/// Split a string into a program name and command line arguments
245 /// the string is assumed to contain a file name followed by other arguments 245 /// the string is assumed to contain a file name followed by other arguments
246 /// the return value contains is a pair with the first argument containing the program name and the second everything 246 /// the return value contains is a pair with the first argument containing the program name and the second everything
247 -/// else 247 +/// else.
248 inline std::pair<std::string, std::string> split_program_name(std::string commandline) { 248 inline std::pair<std::string, std::string> split_program_name(std::string commandline) {
249 // try to determine the programName 249 // try to determine the programName
250 std::pair<std::string, std::string> vals; 250 std::pair<std::string, std::string> vals;