Tools.h++ Class Reference

Table Of Contents
Click on the banner to return to the Class Reference home page.
©Copyright 1996 Rogue Wave Software
RWLocale
Synopsis
Description
Persistence
Enumeration
Public Member Functions
Static Public Member Functions
Synopsis
#include <locale.h>
#include <rw/locale.h>
(Abstract base class)
Description
RWLocale is an abstract base class. It defines an interface for formatting dates (including day
and month names), times, numbers (including digit grouping), and currency, to and from
strings.
Note that because it is an abstract base class, there is no way to actually enforce these goals --
the description here is merely the model of how a class derived from RWLocale should act.
There are three ways to use an RWLocale object:
By passing the object to functions which expect one, such as RWDate::asString().
By specifying a "global" locale using the static member function
RWLocale::global(RWLocale*). This locale is passed as the default argument to
functions that use a locale.
By "imbuing" a stream with the object, so that when an RWDate or RWTime is written to
a stream using operator<<(), the appropriate formatting will be used automatically.