hlcc 2.0.0-beta2+pre1
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Friends | List of all members
boost::gregorian::date Class Reference

A date type based on gregorian_calendar. More...

#include <greg_date.hpp>

Inheritance diagram for boost::gregorian::date:

Public Types

typedef gregorian_calendar::year_type year_type
 
typedef gregorian_calendar::month_type month_type
 
typedef gregorian_calendar::day_type day_type
 
typedef gregorian_calendar::day_of_year_type day_of_year_type
 
typedef gregorian_calendar::ymd_type ymd_type
 
typedef gregorian_calendar::date_rep_type date_rep_type
 
typedef gregorian_calendar::date_int_type date_int_type
 
typedef date_duration duration_type
 

Public Member Functions

BOOST_CXX14_CONSTEXPR date ()
 Default constructor constructs with not_a_date_time.
 
BOOST_CXX14_CONSTEXPR date (year_type y, month_type m, day_type d)
 Main constructor with year, month, day.
 
BOOST_CXX14_CONSTEXPR date (const ymd_type &ymd)
 Constructor from a ymd_type structure.
 
BOOST_CXX14_CONSTEXPR date (const date_int_type &rhs)
 Needed copy constructor.
 
BOOST_CXX14_CONSTEXPR date (date_rep_type rhs)
 Needed copy constructor.
 
BOOST_CXX14_CONSTEXPR date (special_values sv)
 Constructor for infinities, not a date, max and min date.
 
BOOST_CXX14_CONSTEXPR date_int_type julian_day () const
 Return the Julian Day number for the date.
 
BOOST_CXX14_CONSTEXPR day_of_year_type day_of_year () const
 Return the day of year 1..365 or 1..366 (for leap year)
 
BOOST_CXX14_CONSTEXPR date_int_type modjulian_day () const
 Return the Modified Julian Day number for the date.
 
BOOST_CXX14_CONSTEXPR int week_number () const
 Return the iso 8601 week number 1..53.
 
BOOST_CXX14_CONSTEXPR date_int_type day_number () const
 Return the day number from the calendar.
 
BOOST_CXX14_CONSTEXPR date end_of_month () const
 Return the last day of the current month.
 

Friends

BOOST_CXX14_CONSTEXPR bool operator== (const date &lhs, const date &rhs)
 

Detailed Description

A date type based on gregorian_calendar.

This class is the primary interface for programming with greogorian dates. The is a lightweight type that can be freely passed by value. All comparison operators are supported.

Member Typedef Documentation

◆ date_int_type

typedef gregorian_calendar::date_int_type boost::gregorian::date::date_int_type

◆ date_rep_type

typedef gregorian_calendar::date_rep_type boost::gregorian::date::date_rep_type

◆ day_of_year_type

typedef gregorian_calendar::day_of_year_type boost::gregorian::date::day_of_year_type

◆ day_type

typedef gregorian_calendar::day_type boost::gregorian::date::day_type

◆ duration_type

◆ month_type

typedef gregorian_calendar::month_type boost::gregorian::date::month_type

◆ year_type

typedef gregorian_calendar::year_type boost::gregorian::date::year_type

◆ ymd_type

typedef gregorian_calendar::ymd_type boost::gregorian::date::ymd_type

Constructor & Destructor Documentation

◆ date() [1/6]

BOOST_CXX14_CONSTEXPR boost::gregorian::date::date ( )
inline

Default constructor constructs with not_a_date_time.

◆ date() [2/6]

BOOST_CXX14_CONSTEXPR boost::gregorian::date::date ( year_type  y,
month_type  m,
day_type  d 
)
inline

Main constructor with year, month, day.

◆ date() [3/6]

BOOST_CXX14_CONSTEXPR boost::gregorian::date::date ( const ymd_type ymd)
inlineexplicit

Constructor from a ymd_type structure.

◆ date() [4/6]

BOOST_CXX14_CONSTEXPR boost::gregorian::date::date ( const date_int_type rhs)
inlineexplicit

Needed copy constructor.

◆ date() [5/6]

BOOST_CXX14_CONSTEXPR boost::gregorian::date::date ( date_rep_type  rhs)
inlineexplicit

Needed copy constructor.

◆ date() [6/6]

BOOST_CXX14_CONSTEXPR boost::gregorian::date::date ( special_values  sv)
inlineexplicit

Constructor for infinities, not a date, max and min date.

Member Function Documentation

◆ day_number()

BOOST_CXX14_CONSTEXPR date_int_type boost::gregorian::date::day_number ( ) const
inline

Return the day number from the calendar.

◆ day_of_year()

BOOST_CXX14_CONSTEXPR day_of_year_type boost::gregorian::date::day_of_year ( ) const
inline

Return the day of year 1..365 or 1..366 (for leap year)

◆ end_of_month()

BOOST_CXX14_CONSTEXPR date boost::gregorian::date::end_of_month ( ) const
inline

Return the last day of the current month.

◆ julian_day()

BOOST_CXX14_CONSTEXPR date_int_type boost::gregorian::date::julian_day ( ) const
inline

Return the Julian Day number for the date.

◆ modjulian_day()

BOOST_CXX14_CONSTEXPR date_int_type boost::gregorian::date::modjulian_day ( ) const
inline

Return the Modified Julian Day number for the date.

◆ week_number()

BOOST_CXX14_CONSTEXPR int boost::gregorian::date::week_number ( ) const
inline

Return the iso 8601 week number 1..53.

Friends And Related Function Documentation

◆ operator==

BOOST_CXX14_CONSTEXPR bool operator== ( const date lhs,
const date rhs 
)
friend

The documentation for this class was generated from the following file: