A version of the std::less predicate for strings that supports case insensitive comparison.
More...
#include <ookii/string_helper.h>
|
|
using | is_transparent = int |
| | Indicates that this function accepts any type and uses perfect forwarding.
|
| |
|
| | string_less (bool case_sensitive=true, std::locale loc={}) |
| | Initializes a new instance of the string_less class. More...
|
| |
| template<typename Range1 , typename Range2 > |
| bool | operator() (Range1 &&left, Range2 &&right) const |
| | Compares two strings. More...
|
| |
A version of the std::less predicate for strings that supports case insensitive comparison.
◆ string_less()
| ookii::string_less::string_less |
( |
bool |
case_sensitive = true, |
|
|
std::locale |
loc = {} |
|
) |
| |
|
inline |
Initializes a new instance of the string_less class.
- Parameters
-
| case_sensitive | true to perform case sensitive comparisons; false to perform case insensitive comparisons. |
| loc | The locale to use for case insensitive comparisons. This is not used for case sensitive comparisons. |
◆ operator()()
template<typename Range1 , typename Range2 >
| bool ookii::string_less::operator() |
( |
Range1 && |
left, |
|
|
Range2 && |
right |
|
) |
| const |
|
inline |
Compares two strings.
- Template Parameters
-
| Range1 | The type of the first string. |
| Range2 | The type of the second string. |
- Parameters
-
| left | The first string. |
| right | The second string. |
- Returns
true if left is less than right; otherwise, false.
The documentation for this struct was generated from the following file:
- /mnt/d/Sven/Documents/Code/Ookii.CommandLine.Cpp/include/ookii/string_helper.h