Skip to content. Skip to navigation

ICTP Portal

Sections
You are here: Home Manuals on-line PGI Compiler pgC_lib time_get_byname
Personal tools
Document Actions

time_get_byname



Click on the banner to return to the class reference home page.

time_get_byname


time_get_base time_get_bynametime_get locale::facet

Summary

A facet that provides formatted time input facilities based on the named locales.

Data Type and Member Function Indexes
(exclusive of constructors and destructors)

None

Synopsis

#include <locale>
template <class charT, class InputIterator = 
          istreambuf_iterator<charT> >
class time_get_byname;

Description

The time_get_byname template provides the same functionality as the time_get template, but specific to a particular named locale. For a description of the member functions of time_get_byname, see the reference for time_get. Only the constructor is described here.

Interface

template <class charT, class InputIterator =    
          istreambuf_iterator<charT> >
class time_get_byname : public time_get<charT, InputIterator> {
public:
  explicit time_get_byname(const char*, size_t = 0);
protected:
  ~time_get_byname();  // virtual
  virtual dateorder do_date_order()  const;
  virtual iter_type do_get_time(iter_type, iter_type, ios_base&, 
                                ios_base::iostate&, tm*) const;
  virtual iter_type do_get_date(iter_type, iter_type, ios_base&,
                                ios_base::iostate&, tm*) const;
  virtual iter_type do_get_weekday(iter_type, iter_type, ios_base&,
                                 ios_base::iostate& err, tm*) const;
  virtual iter_type do_get_monthname(iter_type, iter_type, ios_base&,
                                     ios_base::iostate&, tm*) const;
  virtual iter_type do_get_year(iter_type, iter_type, ios_base&,
                                ios_base::iostate&, tm*) const;
};

Constructor

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

    Construct a time_get_byname facet. The facet will provide time formatting facilities relative to the named locale specified by the name argument. If the refs argument is 0 then destruction of the object is delegated to the locale, or locales, containing it. This allows the user to ignore lifetime management issues. On the other had, if refs is 1 then the object must be explicitly deleted; the locale will not do so. In this case, the object can be maintained across the lifetime of multiple locales.

See Also

locale, facets, time_get, time_put_byname


©Copyright 1996, Rogue Wave Software, Inc.


Powered by Plone This site conforms to the following standards: