std::locale::facet Class Reference

Localization functionality base class. More...

#include <locale_classes.h>

Inheritance diagram for std::locale::facet:

std::__ctype_abstract_base< _CharT > std::__moneypunct_cache< _CharT, _Intl > std::__numpunct_cache< _CharT > std::__timepunct< _CharT > std::__timepunct_cache< _CharT > std::collate< _CharT > std::ctype< char > std::messages< _CharT > std::money_get< _CharT, _InIter > std::money_put< _CharT, _OutIter > std::moneypunct< _CharT, _Intl > std::num_get< _CharT, _InIter > std::num_put< _CharT, _OutIter > std::numpunct< _CharT > std::time_get< _CharT, _InIter > std::time_put< _CharT, _OutIter > List of all members.

Protected Member Functions

 facet (size_t __refs=0) throw ()
 Facet constructor.
virtual ~facet ()
 Facet destructor.

Static Protected Member Functions

static void _S_create_c_locale (__c_locale &__cloc, const char *__s, __c_locale __old=0)
static __c_locale _S_clone_c_locale (__c_locale &__cloc)
static void _S_destroy_c_locale (__c_locale &__cloc)
static __c_locale _S_get_c_locale ()
static const char * _S_get_c_name ()

Private Member Functions

void _M_add_reference () const throw ()
void _M_remove_reference () const throw ()
 facet (const facet &)
facetoperator= (const facet &)

Static Private Member Functions

static void _S_initialize_once ()

Private Attributes

_Atomic_word _M_refcount

Static Private Attributes

static __c_locale _S_c_locale
static const char _S_c_name [2]

Friends

class locale
class locale::_Impl

Detailed Description

Localization functionality base class.

The facet class is the base class for a localization feature, such as money, time, and number printing. It provides common support for facets and reference management.

Facets may not be copied or assigned.

Definition at line 343 of file locale_classes.h.


Constructor & Destructor Documentation

std::locale::facet::facet ( size_t  __refs = 0  )  throw () [inline, explicit, protected]

Facet constructor.

This is the constructor provided by the standard. If refs is 0, the facet is destroyed when the last referencing locale is destroyed. Otherwise the facet will never be destroyed.

Parameters:
refs The initial value for reference count.

Definition at line 375 of file locale_classes.h.

virtual std::locale::facet::~facet (  )  [protected, virtual]

Facet destructor.

std::locale::facet::facet ( const facet  )  [private]


Member Function Documentation

void std::locale::facet::_M_add_reference (  )  const throw () [inline, private]

Definition at line 402 of file locale_classes.h.

void std::locale::facet::_M_remove_reference (  )  const throw () [inline, private]

Definition at line 406 of file locale_classes.h.

static __c_locale std::locale::facet::_S_clone_c_locale ( __c_locale __cloc  )  [static, protected]

static void std::locale::facet::_S_create_c_locale ( __c_locale __cloc,
const char *  __s,
__c_locale  __old = 0 
) [static, protected]

Referenced by std::collate_byname< _CharT >::collate_byname(), std::moneypunct_byname< _CharT, _Intl >::moneypunct_byname(), and std::numpunct_byname< _CharT >::numpunct_byname().

static void std::locale::facet::_S_destroy_c_locale ( __c_locale __cloc  )  [static, protected]

Referenced by std::collate_byname< _CharT >::collate_byname(), std::moneypunct_byname< _CharT, _Intl >::moneypunct_byname(), std::numpunct_byname< _CharT >::numpunct_byname(), and std::collate< _CharT >::~collate().

static __c_locale std::locale::facet::_S_get_c_locale (  )  [static, protected]

Referenced by std::num_put< _CharT, _OutIter >::_M_insert_float(), std::money_get< _CharT, _InIter >::do_get(), std::num_get< _CharT, _InIter >::do_get(), and std::money_put< _CharT, _OutIter >::do_put().

static const char* std::locale::facet::_S_get_c_name (  )  [static, protected]

static void std::locale::facet::_S_initialize_once (  )  [static, private]

facet& std::locale::facet::operator= ( const facet  )  [private]


Friends And Related Function Documentation

friend class locale [friend]

Definition at line 346 of file locale_classes.h.

Referenced by std::messages< _CharT >::_M_convert_from_char().

friend class locale::_Impl [friend]

Definition at line 347 of file locale_classes.h.


Member Data Documentation

_Atomic_word std::locale::facet::_M_refcount [mutable, private]

Definition at line 349 of file locale_classes.h.

__c_locale std::locale::facet::_S_c_locale [static, private]

Definition at line 352 of file locale_classes.h.

const char std::locale::facet::_S_c_name[2] [static, private]

Definition at line 355 of file locale_classes.h.


The documentation for this class was generated from the following file:
Generated on Tue Feb 2 16:58:59 2010 for GNU C++ STL by  doxygen 1.4.7