public member function
template <class ForwardIterator>
char_class_type lookup_classname ( ForwardIterator first, ForwardIterator last,
bool nocase = false ) const;
Return character class mask
Returns a bitmask value that selects the character class identified by the character sequence between first and last.
The returned value can be used as argument for member function regex_traits::isctype to identify the type of a character.
This function is called when a potential named class name is encountered in a regular expression to obtain the value to be used in subsequent calls to isctype in order to match characters. nocase is set to true if the regex object has icase as a syntax option.
For the char and wchar_t specializations of the standard regex_traits, at least the following names are supported:
* The name is matched without regard to the case of the characters used in the character sequence.
|name*||class description||equivalent check in default locale|
|digit||decimal digit character||isdigit|
|graph||character with graphical representation||isgraph|
|punct||punctuation mark character||ispunct|
|xdigit||hexadecimal digit character||isxdigit|
|d||decimal digit character||isdigit|
- first, last
- Forward iterators to the initial and final positions in a sequence of characters.
The range used is [first,last), which includes all the characters between first and last, including the character pointed by first but not the character pointed by last.
- If true, the returned bitmask is suitable to match characters without regard to their case.
A bitmask value to select the specified character class.
char_class_type is a member type, defined as a bitmask type used to identify character classes.
If the character sequence does not name a supported character class, it returns a value that compares equal to
If the character sequence does not name a supported character class, it returns
A bitmask type may have been implemented in your library either as an enumerated type, an integer type, or a bitset. In any case, it can take one or more flags of that same type as value by combining them using the bitwise OR operator (|).