Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
I/O Stream manipulators
Collaboration diagram for I/O Stream manipulators:

Functions

std::ios_base & boost::locale::as::posix (std::ios_base &ios)
 Format values with "POSIX" or "C" locale. More...
 
std::ios_base & boost::locale::as::number (std::ios_base &ios)
 Format a number. More...
 
std::ios_base & boost::locale::as::currency (std::ios_base &ios)
 Format currency, number is treated like amount of money. More...
 
std::ios_base & boost::locale::as::percent (std::ios_base &ios)
 Format percent, value 0.3 is treated as 30%. More...
 
std::ios_base & boost::locale::as::date (std::ios_base &ios)
 Format a date, number is treated as POSIX time. More...
 
std::ios_base & boost::locale::as::time (std::ios_base &ios)
 Format a time, number is treated as POSIX time. More...
 
std::ios_base & boost::locale::as::datetime (std::ios_base &ios)
 Format a date and time, number is treated as POSIX time. More...
 
std::ios_base & boost::locale::as::strftime (std::ios_base &ios)
 Create formatted date time, Please note, this manipulator only changes formatting mode, and not format itself, so you are probably looking for ftime manipulator. More...
 
std::ios_base & boost::locale::as::spellout (std::ios_base &ios)
 Spell the number, like "one hundred and ten". More...
 
std::ios_base & boost::locale::as::ordinal (std::ios_base &ios)
 Write an order of the number like 4th. More...
 
std::ios_base & boost::locale::as::currency_default (std::ios_base &ios)
 Set default currency formatting style – national, like "$". More...
 
std::ios_base & boost::locale::as::currency_iso (std::ios_base &ios)
 Set ISO currency formatting style, like "USD", (requires ICU >= 4.2) More...
 
std::ios_base & boost::locale::as::currency_national (std::ios_base &ios)
 Set national currency formatting style, like "$". More...
 
std::ios_base & boost::locale::as::time_default (std::ios_base &ios)
 set default (medium) time formatting style More...
 
std::ios_base & boost::locale::as::time_short (std::ios_base &ios)
 set short time formatting style More...
 
std::ios_base & boost::locale::as::time_medium (std::ios_base &ios)
 set medium time formatting style More...
 
std::ios_base & boost::locale::as::time_long (std::ios_base &ios)
 set long time formatting style More...
 
std::ios_base & boost::locale::as::time_full (std::ios_base &ios)
 set full time formatting style More...
 
std::ios_base & boost::locale::as::date_default (std::ios_base &ios)
 set default (medium) date formatting style More...
 
std::ios_base & boost::locale::as::date_short (std::ios_base &ios)
 set short date formatting style More...
 
std::ios_base & boost::locale::as::date_medium (std::ios_base &ios)
 set medium date formatting style More...
 
std::ios_base & boost::locale::as::date_long (std::ios_base &ios)
 set long date formatting style More...
 
std::ios_base & boost::locale::as::date_full (std::ios_base &ios)
 set full date formatting style More...
 
template<typename CharType >
details::add_ftime< CharType > boost::locale::as::ftime (std::basic_string< CharType > const &format)
 Set strftime like formatting string. More...
 
template<typename CharType >
details::add_ftime< CharType > boost::locale::as::ftime (CharType const *format)
 See ftime(std::basic_string<CharType> const &format) More...
 
std::ios_base & boost::locale::as::gmt (std::ios_base &ios)
 Set GMT time zone to stream. More...
 
std::ios_base & boost::locale::as::local_time (std::ios_base &ios)
 Set local time zone to stream. More...
 
details::set_timezone boost::locale::as::time_zone (char const *id)
 Set time zone using id. More...
 
details::set_timezone boost::locale::as::time_zone (std::string const &id)
 Set time zone using id. More...
 
details::set_domain boost::locale::as::domain (std::string const &id)
 Manipulator for switching message domain in ostream,. More...
 

Detailed Description

Function Documentation

std::ios_base& boost::locale::as::currency ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::currency_default ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::currency_iso ( std::ios_base &  ios)
inline

#include <boost_1_57_0/boost/locale/formatting.hpp>

Set ISO currency formatting style, like "USD", (requires ICU >= 4.2)

References boost::locale::ios_info::currency_flags(), boost::locale::flags::currency_iso, and boost::locale::ios_info::get().

std::ios_base& boost::locale::as::currency_national ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::date ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::date_default ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::date_full ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::date_long ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::date_medium ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::date_short ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::datetime ( std::ios_base &  ios)
inline
details::set_domain boost::locale::as::domain ( std::string const &  id)
inline

#include <boost_1_57_0/boost/locale/message.hpp>

Manipulator for switching message domain in ostream,.

Note
The returned object throws std::bad_cast if the I/O stream does not have message_format facet installed

Referenced by boost::locale::basic_message< char_type >::str().

template<typename CharType >
details::add_ftime<CharType> boost::locale::as::ftime ( std::basic_string< CharType > const &  format)

#include <boost_1_57_0/boost/locale/formatting.hpp>

Set strftime like formatting string.

Please note, formatting flags are very similar but not exactly the same as flags for C function strftime. Differences: some flags as "%e" do not add blanks to fill text up to two spaces, not all flags supported.

Flags:

  • "%a" – Abbreviated weekday (Sun.)
  • "%A" – Full weekday (Sunday)
  • "%b" – Abbreviated month (Jan.)
  • "%B" – Full month (January)
  • "%c" – Locale date-time format. Note: prefer using "as::datetime"
  • "%d" – Day of Month [01,31]
  • "%e" – Day of Month [1,31]
  • "%h" – Same as "%b"
  • "%H" – 24 clock hour [00,23]
  • "%I" – 12 clock hour [01,12]
  • "%j" – Day of year [1,366]
  • "%m" – Month [01,12]
  • "%M" – Minute [00,59]
  • "%n" – New Line
  • "%p" – AM/PM in locale representation
  • "%r" – Time with AM/PM, same as "%I:%M:%S %p"
  • "%R" – Same as "%H:%M"
  • "%S" – Second [00,61]
  • "%t" – Tab character
  • "%T" – Same as "%H:%M:%S"
  • "%x" – Local date representation. Note: prefer using "as::date"
  • "%X" – Local time representation. Note: prefer using "as::time"
  • "%y" – Year [00,99]
  • "%Y" – 4 digits year. (2009)
  • "%Z" – Time Zone
  • "%%" – Percent symbol
template<typename CharType >
details::add_ftime<CharType> boost::locale::as::ftime ( CharType const *  format)
std::ios_base& boost::locale::as::gmt ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::local_time ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::number ( std::ios_base &  ios)
inline

#include <boost_1_57_0/boost/locale/formatting.hpp>

Format a number.

Note, unlike standard number formatting, integers would be treated like real numbers when std::fixed or std::scientific manipulators were applied

References boost::locale::ios_info::display_flags(), boost::locale::ios_info::get(), and boost::locale::flags::number.

std::ios_base& boost::locale::as::ordinal ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::percent ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::posix ( std::ios_base &  ios)
inline

#include <boost_1_57_0/boost/locale/formatting.hpp>

Format values with "POSIX" or "C" locale.

Note, if locale was created with additional non-classic locale then These numbers may be localized

References boost::locale::ios_info::display_flags(), boost::locale::ios_info::get(), and boost::locale::flags::posix.

std::ios_base& boost::locale::as::spellout ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::strftime ( std::ios_base &  ios)
inline

#include <boost_1_57_0/boost/locale/formatting.hpp>

Create formatted date time, Please note, this manipulator only changes formatting mode, and not format itself, so you are probably looking for ftime manipulator.

References boost::locale::ios_info::display_flags(), boost::locale::ios_info::get(), and boost::locale::flags::strftime.

std::ios_base& boost::locale::as::time ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::time_default ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::time_full ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::time_long ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::time_medium ( std::ios_base &  ios)
inline
std::ios_base& boost::locale::as::time_short ( std::ios_base &  ios)
inline
details::set_timezone boost::locale::as::time_zone ( char const *  id)
inline

#include <boost_1_57_0/boost/locale/formatting.hpp>

Set time zone using id.

References boost::chrono::set_timezone().

details::set_timezone boost::locale::as::time_zone ( std::string const &  id)
inline

#include <boost_1_57_0/boost/locale/formatting.hpp>

Set time zone using id.

References boost::chrono::set_timezone().