jpman project specific RCS keyword (jpman %Id) is obsolete, after manual entries are stored in freefall CVS repository. This old Id is useless and more worse it confuses users and bug reporters. So, this old Id is removed. Submitted by:jpman project <man-jp@jp.FreeBSD.org>
89 lines
2.5 KiB
Groff
89 lines
2.5 KiB
Groff
.\"
|
|
.\" Copyright (c) 1997 Joerg Wunsch
|
|
.\"
|
|
.\" All rights reserved.
|
|
.\"
|
|
.\" Redistribution and use in source and binary forms, with or without
|
|
.\" modification, are permitted provided that the following conditions
|
|
.\" are met:
|
|
.\" 1. Redistributions of source code must retain the above copyright
|
|
.\" notice, this list of conditions and the following disclaimer.
|
|
.\" 2. Redistributions in binary form must reproduce the above copyright
|
|
.\" notice, this list of conditions and the following disclaimer in the
|
|
.\" documentation and/or other materials provided with the distribution.
|
|
.\"
|
|
.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR
|
|
.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
|
.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
|
.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
|
.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
|
.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
|
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
.\"
|
|
.\" %Id: strptime.3,v 1.2 1998/09/12 21:13:29 dt Exp %
|
|
.\" "
|
|
.\" $FreeBSD$
|
|
.Dd May 8, 1997
|
|
.Dt STRPTIME 3
|
|
.Os
|
|
.Sh 名称
|
|
.Nm strptime
|
|
.Nd 日付および時刻を表す文字列を解釈する
|
|
.Sh 書式
|
|
.Fd #include <time.h>
|
|
.Ft char *
|
|
.Fn strptime "const char *buf" "const char *format" "struct tm *timeptr"
|
|
.Sh 解説
|
|
.Fn strptime
|
|
関数は、バッファ
|
|
.Fa buf
|
|
中の文字列を
|
|
.Fa format
|
|
で示される文字列に従って解釈し、
|
|
.Fa timeptr
|
|
が指す構造体の要素に入れます。
|
|
したがって、これは
|
|
.Xr strftime 3
|
|
の逆方向の操作と考えることができます。
|
|
.Pp
|
|
.Fa format
|
|
文字列は、ゼロ以上の変換則と通常文字からなります。
|
|
すべての通常文字は、バッファと厳密にマッチされます。
|
|
そして、フォーマット文字列の空白文字は
|
|
バッファ中の任意の数の空白文字とマッチします。
|
|
すべての変換則は、
|
|
.Xr strftime 3
|
|
に記述したものと同じです。
|
|
.Sh 戻り値
|
|
成功して終了した場合、
|
|
.Fn strptime
|
|
は
|
|
.Fa format
|
|
中の変換則を満足させるためには要求されなかった、
|
|
.Fa buf
|
|
中の最初の文字へのポインタを返します。
|
|
変換が一つでも失敗した場合は
|
|
.Dv NULL
|
|
を返します。
|
|
.Sh 参照
|
|
.Xr date 1 ,
|
|
.Xr scanf 3 ,
|
|
.Xr strftime 3
|
|
.Sh 作者
|
|
.Fn strptime
|
|
関数は、
|
|
Powerdog Industries
|
|
によって寄贈されました。
|
|
.Pp
|
|
このマニュアルページは、
|
|
.ie t J\(:org Wunsch
|
|
.el Joerg Wunsch
|
|
によって書かれました。
|
|
.Sh 歴史
|
|
.Fn strptime
|
|
関数は、
|
|
.Fx 3.0
|
|
に現れました。
|