ctype::do_is

A virtual function called to test whether a single character has a particular attribute, or classify the attributes of each character in a range and stores them in an array.

virtual bool do_is(
    mask _MaskVal, 
    CharType _Ch
) const;
virtual const CharType *do_is(
    const CharType* _First, 
    const CharType* _Last,
    mask* _Dest
) const;

Parameters

  • _MaskVal
    The mask value for which the character is to be tested.

  • _Ch
    The character whose attributes are to be tested.

  • _First
    A pointer to the first character in the range whose attributes are to be classified.

  • _Last
    A pointer to the last character in the range whose attributes are to be classified.

  • _Dest
    A pointer to the beginning of the array where the mask values characterizing the attributes of each of the characters are to be stored.

Return Value

The first member function returns a Boolean value that is true if the character tested has the attribute described by the mask value; false if it fails to have the attribute.

The second member function returns an array containing the mask values characterizing the attributes of each of the characters in the range.

Remarks

The mask values classifying the attributes of the characters are provided by the class ctype_base, from which ctype derives. The first member function can accept expressions for its first parameter referred to as bitmasks and formed from the combination of mask values by the logical bitwise operators (| , & , ^ , ~).

Example

See the example for is, which calls do_is.

Requirements

Header: <locale>

Namespace: std

See Also

Concepts

ctype Class

ctype Members