New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
gregorian_types.hpp in vendors/XIOS/current/extern/boost/include/boost/date_time/gregorian – NEMO

source: vendors/XIOS/current/extern/boost/include/boost/date_time/gregorian/gregorian_types.hpp @ 3408

Last change on this file since 3408 was 3408, checked in by rblod, 12 years ago

importing initial XIOS vendor drop

  • Property svn:keywords set to Id
File size: 3.6 KB
Line 
1#ifndef _GREGORIAN_TYPES_HPP__
2#define _GREGORIAN_TYPES_HPP__
3
4/* Copyright (c) 2002,2003 CrystalClear Software, Inc.
5 * Use, modification and distribution is subject to the
6 * Boost Software License, Version 1.0. (See accompanying
7 * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
8 * Author: Jeff Garland, Bart Garst
9 * $Date: 2008-02-27 15:00:24 -0500 (Wed, 27 Feb 2008) $
10 */
11
12/*! @file gregorian_types.hpp
13  Single file header that defines most of the types for the gregorian
14  date-time system.
15*/
16
17#include "boost/date_time/date.hpp"
18#include "boost/date_time/period.hpp"
19#include "boost/date_time/gregorian/greg_calendar.hpp"
20#include "boost/date_time/gregorian/greg_duration.hpp"
21#if defined(BOOST_DATE_TIME_OPTIONAL_GREGORIAN_TYPES)
22#include "boost/date_time/gregorian/greg_duration_types.hpp"
23#endif
24#include "boost/date_time/gregorian/greg_date.hpp"
25#include "boost/date_time/date_generators.hpp"
26#include "boost/date_time/date_clock_device.hpp"
27#include "boost/date_time/date_iterator.hpp"
28#include "boost/date_time/adjust_functors.hpp"
29
30namespace boost {
31
32//! Gregorian date system based on date_time components
33/*! This date system defines a full complement of types including
34 *  a date, date_duration, date_period, day_clock, and a
35 *  day_iterator.
36 */
37namespace gregorian {
38  //! Date periods for the gregorian system
39  /*!\ingroup date_basics
40   */
41  typedef date_time::period<date, date_duration> date_period; 
42
43  //! A unifying date_generator base type
44  /*! A unifying date_generator base type for:
45   * partial_date, nth_day_of_the_week_in_month,
46   * first_day_of_the_week_in_month, and last_day_of_the_week_in_month
47   */
48  typedef date_time::year_based_generator<date> year_based_generator;
49
50  //! A date generation object type
51  typedef date_time::partial_date<date> partial_date;
52
53  typedef date_time::nth_kday_of_month<date> nth_kday_of_month;
54  typedef nth_kday_of_month nth_day_of_the_week_in_month;
55
56  typedef date_time::first_kday_of_month<date> first_kday_of_month;
57  typedef first_kday_of_month first_day_of_the_week_in_month;
58
59  typedef date_time::last_kday_of_month<date> last_kday_of_month;
60  typedef last_kday_of_month last_day_of_the_week_in_month;
61
62  typedef date_time::first_kday_after<date> first_kday_after;
63  typedef first_kday_after first_day_of_the_week_after;
64
65  typedef date_time::first_kday_before<date> first_kday_before;
66  typedef first_kday_before first_day_of_the_week_before;
67
68  //! A clock to get the current day from the local computer
69  /*!\ingroup date_basics
70   */
71  typedef date_time::day_clock<date> day_clock;
72
73  //! Base date_iterator type for gregorian types.
74  /*!\ingroup date_basics
75   */
76  typedef date_time::date_itr_base<date> date_iterator;
77
78  //! A day level iterator
79  /*!\ingroup date_basics
80   */
81  typedef date_time::date_itr<date_time::day_functor<date>,
82                              date> day_iterator;
83  //! A week level iterator
84  /*!\ingroup date_basics
85   */
86  typedef date_time::date_itr<date_time::week_functor<date>,
87                              date> week_iterator;
88  //! A month level iterator
89  /*!\ingroup date_basics
90   */
91  typedef date_time::date_itr<date_time::month_functor<date>,
92                              date> month_iterator;
93  //! A year level iterator
94  /*!\ingroup date_basics
95   */
96  typedef date_time::date_itr<date_time::year_functor<date>,
97                              date> year_iterator;
98
99  // bring in these date_generator functions from date_time namespace
100  using date_time::days_until_weekday;
101  using date_time::days_before_weekday;
102  using date_time::next_weekday;
103  using date_time::previous_weekday;
104
105} } //namespace gregorian
106
107
108
109#endif
Note: See TracBrowser for help on using the repository browser.