template< class CharT >
class regex_traits;
The type trait template regex_traits
supplies std::basic_regex with the set of types and functions necessary to operate on the type CharT
.
Since many of regex operations are locale-sensitive (when std::regex_constants::collate flag is set), the regex_traits class typically holds an instance of a std::locale as a private member.
[edit] Standard specializationsTwo specializations of std::regex_traits
are defined by the standard library:
std::regex_traits<char>
std::regex_traits<wchar_t>
These specializations make it possible to use std::basic_regex<char> (aka std::regex) and std::basic_regex<wchar_t> (aka std::wregex). To use std::basic_regex with other character types (for example, char32_t), a user-provided trait class must be used.
[edit] Member types Type Definitionchar_type
CharT
string_type
std::basic_string<CharT> locale_type
The locale used for localized behavior in the regular expression. Must be CopyConstructible char_class_type
Represents a character classification and is capable of holding an implementation specific set returned by lookup_classname
. Must be a BitmaskType. [edit] Member functions constructs the regex_traits object
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4