Standard C++ Library Reference ISO/IEC (VERSION3)
no_order specifies no particular order.●
dmy specifies the order day, month, then year, as in 2 December 1979.●
mdy specifies the order month, day, then year, as in December 2, 1979.●
ymd specifies the order year, month, then day, as in 1979/12/2.●
ydm specifies the order year, day, then month, as in 1979: 2 Dec.●
time_get
template<class Elem, class InIt = istreambuf_iterator<Elem> >
class time_get : public locale::facet, time_base {
public:
typedef Elem char_type;
typedef InIt iter_type;
explicit time_get(size_t refs = 0);
dateorder date_order() const;
iter_type get_time(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
iter_type get_date(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
iter_type get_weekday(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
iter_type get_month(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
iter_type get_year(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
static locale::id id;
protected:
~time_get();
virtual dateorder do_date_order() const;
virtual iter_type
do_get_time(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
virtual iter_type
do_get_date(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
virtual iter_type
do_get_weekday(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
virtual iter_type
do_get_month(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
virtual iter_type
do_get_year(iter_type first, iter_type last,
ios_base& iosbase, ios_base::iostate& state, tm *pt) const;
};
The template class describes an object that can serve as a localefacet, to control conversions of sequences of type Elem
to time values.
As with any locale facet, the static object id has an initial stored value of zero. The first attempt to access its stored
value stores a unique positive value in id.