Movatterモバイル変換


[0]ホーム

URL:


cppreference.com
Namespaces
Variants
    Actions

      std::chrono::month

      From cppreference.com
      <cpp‎ |chrono
       
       
      Date and time library
       
       
      Defined in header<chrono>
      class month;
      (since C++20)
      inlineconstexpr std::chrono::month January{1};
      (since C++20)
      inlineconstexpr std::chrono::month February{2};
      (since C++20)
      inlineconstexpr std::chrono::month March{3};
      (since C++20)
      inlineconstexpr std::chrono::month April{4};
      (since C++20)
      inlineconstexpr std::chrono::month May{5};
      (since C++20)
      inlineconstexpr std::chrono::month June{6};
      (since C++20)
      inlineconstexpr std::chrono::month July{7};
      (since C++20)
      inlineconstexpr std::chrono::month August{8};
      (since C++20)
      inlineconstexpr std::chrono::month September{9};
      (since C++20)
      inlineconstexpr std::chrono::month October{10};
      (since C++20)
      inlineconstexpr std::chrono::month November{11};
      (since C++20)
      inlineconstexpr std::chrono::month December{12};
      (since C++20)

      The classmonth represents a month in a year. Its normal range is[112], but it may hold any number in[0255]. Twelve named constants are predefined in thestd::chrono namespace for the twelve months of the year.

      month is aTriviallyCopyableStandardLayoutType.

      [edit]Member functions

      constructs amonth
      (public member function)[edit]
      increments or decrements the month
      (public member function)[edit]
      adds or subtracts a number of months
      (public member function)[edit]
      retrieves the stored month value
      (public member function)[edit]
      checks if the stored month value is in the normal range
      (public member function)[edit]

      [edit]Nonmember functions

      compares twomonth values
      (function)[edit]
      performs arithmetic onmonths
      (function)[edit]
      (C++20)
      outputs amonth into a stream
      (function template)[edit]
      parses amonth from a stream according to the provided format
      (function template)[edit]

      [edit]Helper classes

      formatting support formonth
      (class template specialization)[edit]
      hash support forstd::chrono::month
      (class template specialization)
      Retrieved from "https://en.cppreference.com/mwiki/index.php?title=cpp/chrono/month&oldid=157851"

      [8]ページ先頭

      ©2009-2025 Movatter.jp