Apache C++ Standard Library Reference Guide

## ctype_byname

Library: Localization

                           ctype_base
    ctype_byname  ctype
                           locale::facet

- Local Index
- Summary
- Synopsis
- Specializations
- Description
- Interface
- Constructors
- See Also
- Standards Conformance

### Local Index

#### Members

ctype_byname() |

### Summary

A facet that includes character classification facilities based on the named locales

### Synopsis

    #include <locale>

    namespace std {
      template <class charT> class ctype_byname;
      template <> class ctype_byname<char>;
    }

### Specializations

    namespace std {
    template <> class ctype_byname<char>;
    template <> class ctype_byname<wchar_t>;
    }

### Description

The ctype_byname template and ctype_byname<char> specialization include the same functions as the ctype template, but specific to a particular named locale. For a description of the member functions of ctype_byname, see the entry for ctype. Only the constructor is described here.

### Interface

    namespace std {
      template <class charT>
      class ctype_byname : public ctype<charT> {
      public:
        explicit ctype_byname(const char*, size_t = 0);
        };
      class ctype_byname<char> : public ctype<char> {
      public:
        explicit ctype_byname(const char*, size_t = 0);
        };
    }

### Constructors

    explicit ctype_byname(const char* name, size_t refs = 0);

Constructs a ctype_byname object for the locale given by name. Calls `ctype<char_type>::ctype (refs)`.

### See Also

locale, Facets, collate, ctype

### Standards Conformance

ISO/IEC 14882:1998 -- International Standard for Information Systems -- Programming Language C++, Section 22.2.1.2