Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

Class template months_duration

boost::date_time::months_duration — additional duration type that represents a logical month

Synopsis

// In header: <boost/date_time/date_duration_types.hpp>

template<typename base_config> 
class months_duration {
public:
  // construct/copy/destruct
  ();
  ();

  // public member functions
   () ;
  BOOST_CXX14_CONSTEXPR  (const ) ;
  BOOST_CXX14_CONSTEXPR  (const ) ;
  BOOST_CONSTEXPR bool (const months_type &) ;
  BOOST_CONSTEXPR bool (const months_type &) ;
  BOOST_CXX14_CONSTEXPR months_type (const months_type &) ;
  BOOST_CXX14_CONSTEXPR months_type & (const months_type &);
  BOOST_CXX14_CONSTEXPR months_type (const months_type &) ;
  BOOST_CXX14_CONSTEXPR months_type & (const months_type &);
  BOOST_CXX14_CONSTEXPR months_type (const ) ;
  BOOST_CXX14_CONSTEXPR months_type & (const );
  BOOST_CXX14_CONSTEXPR months_type (const ) ;
  BOOST_CXX14_CONSTEXPR months_type & (const );
  BOOST_CXX14_CONSTEXPR months_type (const years_type &) ;
  BOOST_CXX14_CONSTEXPR months_type & (const years_type &);
  BOOST_CXX14_CONSTEXPR months_type (const years_type &) ;
  BOOST_CXX14_CONSTEXPR months_type & (const years_type &);
};

Description

A logical month enables things like: "date(2002,Mar,2) + months(2) -> 2002-May2". If the date is a last day-of-the-month, the result will also be a last-day-of-the-month.

months_duration public construct/copy/destruct

  1. ( num);
  2. ( sv);

months_duration public member functions

  1.  () ;
  2. BOOST_CXX14_CONSTEXPR  (const  d) ;
    returns a negative duration
  3. BOOST_CXX14_CONSTEXPR  (const  d) ;
  4. BOOST_CONSTEXPR bool (const months_type & rhs) ;
  5. BOOST_CONSTEXPR bool (const months_type & rhs) ;
  6. BOOST_CXX14_CONSTEXPR months_type (const months_type & rhs) ;
  7. BOOST_CXX14_CONSTEXPR months_type & (const months_type & rhs);
  8. BOOST_CXX14_CONSTEXPR months_type (const months_type & rhs) ;
  9. BOOST_CXX14_CONSTEXPR months_type & (const months_type & rhs);
  10. BOOST_CXX14_CONSTEXPR months_type (const  rhs) ;
  11. BOOST_CXX14_CONSTEXPR months_type & (const  rhs);
  12. BOOST_CXX14_CONSTEXPR months_type (const  rhs) ;
  13. BOOST_CXX14_CONSTEXPR months_type & (const  rhs);
  14. BOOST_CXX14_CONSTEXPR months_type (const years_type & y) ;
  15. BOOST_CXX14_CONSTEXPR months_type & (const years_type & y);
  16. BOOST_CXX14_CONSTEXPR months_type (const years_type & y) ;
  17. BOOST_CXX14_CONSTEXPR months_type & (const years_type & y);

PrevUpHomeNext