O'Reilly logo

C++ In a Nutshell by Ray Lischner

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

codecvt class template — Facet for mapping one character set to another

Synopsis

template <typename internT,typename externT,typename stateT>
class codecvt : public locale::facet, public codecvt_base
{
public:
  typedef internT intern_type;
  typedef externT extern_type;
  typedef stateT state_type;
  explicit codecvt(size_t refs = 0);
  result out(stateT& state, const internT* from, const internT* from_end,
             const internT*& from_next, externT* to, externT* to_limit, 
             externT*& to_next) const;
  result unshift(stateT& state, externT* to, externT* to_limit, 
                 externT*& to_next) const;
  result in(stateT& state, const externT* from, const externT* from_end,
            const externT*& from_next, internT* to, internT* to_limit, 
            internT*& to_next) const;
  int encoding(  ) const throw(  );
  bool always_noconv(  ) const throw(  );
  int length(stateT&, const externT* from, const externT* end, size_t max)
    const;
  int max_length(  ) const throw(  );
  static locale::id id;
protected:
  virtual ~codecvt(  );
  virtual result do_out(stateT& state, const internT* from, 
                        const internT* from_end, const internT*& from_next, 
                        externT* to, externT* to_limit, externT*& to_next)
    const;
  virtual result do_in(stateT& state, const externT* from, 
                       const externT* from_end, const externT*& from_next,
                       internT* to, internT* to_limit, internT*& to_next)
    const;
  virtual result do_unshift(stateT& state, externT* to, externT* to_limit,
                            externT*& to_next) const;
  virtual int do_encoding(  ) const throw(  );
  virtual bool do_always_noconv( ) const throw( ); virtual ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required