parseUnsignedInteger overloads
Synopses
Declared in <bdlb_numericparseutil.h>
Parse an unsigned integer not exceeding maxValue from a string.
static
int
parseUnsignedInteger(
bsls::Types::Uint64* result,
std::string_view const& inputString,
int base,
bsls::Types::Uint64 const maxValue);
Parse an unsigned integer with a digit‐count limit from a string.
static
int
parseUnsignedInteger(
bsls::Types::Uint64* result,
std::string_view const& inputString,
int base,
bsls::Types::Uint64 const maxValue,
int maxNumDigits);
Parse a bounded unsigned integer from a string, also returning the suffix.
static
int
parseUnsignedInteger(
bsls::Types::Uint64* result,
std::string_view* remainder,
std::string_view const& inputString,
int base,
bsls::Types::Uint64 const maxValue);
Parse a digit‐limited unsigned integer from a string, also returning the suffix.
static
int
parseUnsignedInteger(
bsls::Types::Uint64* result,
std::string_view* remainder,
std::string_view const& inputString,
int base,
bsls::Types::Uint64 const maxValue,
int maxNumDigits);
Return Value
0 on success, and a non‐zero value otherwise
Parameters
Name |
Description |
result |
location to store the parsed value |
inputString |
text to parse |
base |
numeric base in |
maxValue |
highest acceptable parsed value |
maxNumDigits |
maximum number of digit characters to consume |
remainder |
unparsed suffix of |
Created with MrDocs