The class regex is parameterized around a set of related types and functions used to complete the definition of its semantics. This class satisfies the requirements of such a traits class.
Definition at line 352 of file tr1_impl/regex.
std::regex_traits< _Ch_type >::regex_traits | ( | ) | [inline] |
locale_type std::regex_traits< _Ch_type >::getloc | ( | ) | const [inline] |
Gets a copy of the current locale in use by the regex_traits object.
Definition at line 600 of file tr1_impl/regex.
References std::regex_traits< _Ch_type >::_M_locale.
locale_type std::regex_traits< _Ch_type >::imbue | ( | locale_type | __loc | ) | [inline] |
Imbues the regex_traits object with a copy of a new locale.
loc | A locale. |
Definition at line 589 of file tr1_impl/regex.
References std::regex_traits< _Ch_type >::_M_locale, and std::swap().
bool std::regex_traits< _Ch_type >::isctype | ( | _Ch_type | __c, | |
char_class_type | __f | |||
) | const [inline] |
Determines if c
is a member of an identified class.
c | a character. | |
f | a class type (as returned from lookup_classname). |
c
is a member of the classification represented by f
, false otherwise.std::bad_cast | if the current locale does not have a ctype facet. |
Definition at line 529 of file tr1_impl/regex.
References std::regex_traits< _Ch_type >::_M_locale, std::__ctype_abstract_base< _CharT >::is(), std::regex_traits< _Ch_type >::lookup_classname(), std::use_facet(), and std::__ctype_abstract_base< _CharT >::widen().
static std::size_t std::regex_traits< _Ch_type >::length | ( | const char_type * | __p | ) | [inline, static] |
Gives the length of a C-style string starting at __p
.
__p | a pointer to the start of a character sequence. |
*__p
and the first default-initialized value of type char_type
. In other words, uses the C-string algorithm for determining the length of a sequence of characters. Definition at line 378 of file tr1_impl/regex.
char_class_type std::regex_traits< _Ch_type >::lookup_classname | ( | _Fwd_iter | __first, | |
_Fwd_iter | __last | |||
) | const [inline] |
Maps one or mire characters to a named character classification.
first | beginning of the character sequence. | |
last | one-past-the-end of the character sequence. |
Definition at line 513 of file tr1_impl/regex.
Referenced by std::regex_traits< _Ch_type >::isctype().
string_type std::regex_traits< _Ch_type >::lookup_collatename | ( | _Fwd_iter | __first, | |
_Fwd_iter | __last | |||
) | const [inline] |
Gets a collation element by name.
first | beginning of the collation element name. | |
last | one-past-the-end of the collation element name. |
Definition at line 475 of file tr1_impl/regex.
string_type std::regex_traits< _Ch_type >::transform | ( | _Fwd_iter | __first, | |
_Fwd_iter | __last | |||
) | const [inline] |
Gets a sort key for a character sequence.
first | beginning of the character sequence. | |
last | one-past-the-end of the character sequence. |
What this really does is provide a more efficient way to compare a string to multiple other strings in locales with fancy collation rules and equivalence classes.
std::bad_cast | if the current locale does not have a collate facet. |
Definition at line 431 of file tr1_impl/regex.
References std::regex_traits< _Ch_type >::_M_locale, std::basic_string< _CharT, _Traits, _Alloc >::data(), std::basic_string< _CharT, _Traits, _Alloc >::size(), std::collate< _CharT >::transform(), and std::use_facet().
string_type std::regex_traits< _Ch_type >::transform_primary | ( | _Fwd_iter | __first, | |
_Fwd_iter | __last | |||
) | const [inline] |
Dunno.
first | beginning of the character sequence. | |
last | one-past-the-end of the character sequence. |
Definition at line 457 of file tr1_impl/regex.
char_type std::regex_traits< _Ch_type >::translate | ( | char_type | __c | ) | const [inline] |
Performs the identity translation.
c | A character to the locale-specific character set. |
Definition at line 389 of file tr1_impl/regex.
char_type std::regex_traits< _Ch_type >::translate_nocase | ( | char_type | __c | ) | const [inline] |
Translates a character into a case-insensitive equivalent.
c | A character to the locale-specific character set. |
std::bad_cast | if the imbued locale does not support the ctype facet. |
Definition at line 402 of file tr1_impl/regex.
References std::regex_traits< _Ch_type >::_M_locale, std::tolower(), and std::use_facet().
int std::regex_traits< _Ch_type >::value | ( | _Ch_type | __ch, | |
int | __radix | |||
) | const |
Converts a digit to an int.
ch | a character representing a digit. | |
radix | the radix if the numeric conversion (limited to 8, 10, or 16). |