ftime

FTIME(3)                   Linux Programmer's Manual                  FTIME(3)



åå
       ftime - æ¥ä»ã¨æéãè¿ã

æ¸å¼
       #include <sys/timeb.h>

       int ftime(struct timeb *tp);

説æ
       ãã®é¢æ°ã¯ç¾å¨ã®æå»ããç´å (Epoch; 1970-01-01 00:00:00 +0000 (UTC))
       ããã®ç§æ°ã¨ããªç§æ°ã§è¿ãã æå»ã¯ tp ã§è¿ãããããã¯ä»¥ä¸ã®ããã«å®ç¾©ããã¦ãã:

           struct timeb {
               time_t         time;
               unsigned short millitm;
               short          timezone;
               short          dstflag;
           };

       ããã§ãtime ã¯ç´å (the Epoch) ããã®ç§æ°ã millitm 㯠ç´åãã time
       ç§å¾ããã®ããªç§æ°ã§ããã timezone ãã£ã¼ã«ãã¯ã°ãªããã¸ãã西å¨ãã®åã§è¨æ¸¬ããã
       ãã¼ã«ã«ã¿ã¤ã ã¾ã¼ã³ã§ãã(è² æ°ã®å ´åã¯ã°ãªããã¸ããã®æ±åãã®åã 示ã)ã
       dstflag ãã£ã¼ã«ãã¯ããã 0 ã§ãªããã°ä¸å¹´ã®ä¸é¨ã§å¤æéã å‐
       å¨ãããã¨ã示ããã©ã°ã§ããã

       POSIX.1-2001 ã§ã¯ãtimezone 㨠dstflag ã®å容ã¯æªå®ç¾©ã§ãã;
       ããã«é ¼ãã®ã¯é¿ãããã¨ã

è¿ãå¤
       ãã®é¢æ°ã¯å¸¸ã« 0 ãè¿ãã (POSIX.1-2001 ä»æ§åã³ããã¤ãã®ã·ã¹ãã ã®ãã‐
       ã¥ã¡ã³ãã§ã¯ã ã¨ã©ã¼æã« -1 ãè¿ãã)

æºæ
       4.2BSD, POSIX.1-2001.  POSIX.1-2008 ã§ã¯ ftime()  ã®ä»æ§ãåé¤ããã¦ããã

       ãã®é¢æ°ã¯å¤ããã®ã§ããã使ã£ã¦ã¯ãªããªãã ç§åä½ã®æéã§ååãªãã time(2)
       ãå©ç¨ã§ããã gettimeofday(2) ã§ãã¤ã¯ãç§ãå¾ãããã clock_gettime(2)
       ã§ããç§ãå¾ãããããåºãå©ç¨å¯è½ãªè¨³ã§ã¯ãªãã

ãã°
       millitm ãã£ã¼ã«ãã¯ãlibc4 㨠libc5 ã§ã¯æ£ããåä½ããã ããããåæã® glibc2
       ã§ã¯ãã°ãããã常㫠0 ãè¿ãã glibc 2.1.1 ããåã³æ£å¸¸ã«ãªã£ãã

é¢é£é ç®
       gettimeofday(2), time(2)

ãã®ææ¸ã«ã¤ãã¦
       ãã® man ãã¼ã¸ã¯ Linux man-pages ããã¸ã§ã¯ãã®ãªãªã¼ã¹ 3.51 ã®ä¸é¨
       ã§ãããããã¸ã§ã¯ãã®èª¬æã¨ãã°å ±åã«é¢ããæå ±ã¯
       http://www.kernel.org/doc/man-pages/ ã«æ¸ããã¦ããã



GNU                               2010-02-25                          FTIME(3)