.\" Copyright 2001 Walter Harms (walter.harms@informatik.uni-oldenburg.de) .\" .\" Permission is granted to make and distribute verbatim copies of this .\" manual provided the copyright notice and this permission notice are .\" preserved on all copies. .\" .\" Permission is granted to copy and distribute modified versions of this .\" manual under the conditions for verbatim copying, provided that the .\" entire resulting derived work is distributed under the terms of a .\" permission notice identical to this one. .\" .\" Since the Linux kernel and libraries are constantly changing, this .\" manual page may be incorrect or out-of-date. The author(s) assume no .\" responsibility for errors or omissions, or for damages resulting from .\" the use of the information contained herein. The author(s) may not .\" have taken the same level of care in the production of this manual, .\" which is licensed free of charge, as they might when working .\" professionally. .\" .\" Formatted or processed versions of this manual, if unaccompanied by .\" the source, must acknowledge the copyright and authors of this work. .\" .\" aeb: some corrections .\" .\" Japanese Version Copyright (c) 2002 NAKANO Takeo all rights reserved. .\" Translated Sun 6 Jan 2002 by NAKANO Takeo .\" .TH DYSIZE 3 2010-09-22 "GNU" "Linux Programmer's Manual" .\"O .SH NAME .\"O dysize \- get number of days for a given year .SH 名前 dysize \- 与えた年の日数を返す .\"O .SH SYNOPSIS .SH 書式 .B "#include " .sp .BI "int dysize(int " year ); .sp .in -4n .\"O Feature Test Macro Requirements for glibc (see .\"O .BR feature_test_macros (7)): glibc 向けの機能検査マクロの要件 .RB ( feature_test_macros (7) 参照): .in .sp .BR dysize (): _BSD_SOURCE || _SVID_SOURCE .\"O .SH DESCRIPTION .SH 説明 .\"O The function returns 365 for a normal year and 366 for a leap year. .\"O The calculation for leap year is based on: この関数は通常の年には 365 を返し、うるう年には 366 を返す。 うるう年の計算は次の式による: .sp (year) %4 == 0 && ((year) %100 != 0 || (year) %400 == 0) .sp .\"O The formula is defined in the macro .\"O .I __isleap(year) .\"O also found in .\"O .IR . この式は .I __isleap(year) マクロで定義されており、 .I にもある。 .\"O .SH "CONFORMING TO" .SH 準拠 .\"O This function occurs in SunOS 4.x. この関数は SunOS 4.x で生まれた。 .\"O .SH NOTES .SH 注意 .\"O This is a compatibility function only. .\"O Don't use it in new programs. .\"O .\" The SCO version of this function had a year-2000 problem. これは互換用の関数に過ぎない。新しいプログラムでは使わないこと。 .\" この関数の SCO 版には 2000 年問題が含まれていた。 .\"O .SH "SEE ALSO" .SH 関連項目 .BR strftime (3)