📄 time.3
字号:
.\" SCCSID: @(#)time.3 2.1 3/10/87.TH time 3.SH Nametime, ftime \- get date and time.SH Syntax.nf.B #include <time.h>.PP.B "time_t time((time_t *)0)".PP.B time_t time(\fItloc\fP).B time_t *\fItloc\fP;.PP.B #include <sys/timeb.h>.PP.B void ftime(\fItp\fP).B struct timeb *\fItp\fP;.fi.SH Description.NXR "time subroutine (standard C)".NXR "ftime subroutine".NXR "time" "getting".NXR "date" "getting"The.PN timesubroutinereturns the time since 00:00:00 GMT, Jan. 1, 1970, measuredin seconds..PPIf.I tlocis nonnull,the return value is also stored in theplace to which.I tlocpoints..PPThe.PN ftimeentry fills in a structure pointed to by its argument,as defined by <sys/timeb.h>:.EXstruct timeb{ time_t time; unsigned short millitm; short timezone; short dstflag;};.EE.PPThe structure contains the time since the epoch in seconds,up to 1000 milliseconds of more-precise interval,the local time zone(measured in minutes of time westward from Greenwich),and a flag that, if nonzero, indicates thatDaylight Saving time applies locallyduring the appropriate part of the year..SH See Alsodate(1), gettimeofday(2), settimeofday(2), ctime(3)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -