Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

utime(2)

time(2)

asctime(3C)

clock(3C)

ctime(3C)

daylight(3C)

difftime(3C)

getdate(3C)

gmtime(3C)

localtime(3C)

mktime(3C)

strftime(3C)

strptime(3C)

sysconf(3C)

timezone(3C)

tzname(3C)

tzset(3C)

time(5)                                                             time(5)

NAME
     time - time types

SYNOPSIS
     #include <time.h>

DESCRIPTION
     The <time.h> header declares the structure tm, which includes at least
     the following members:

     int tmsec      Seconds [0,61]
     int tmmin      Minutes [0,59]
     int tmhour     Hour [0,23]
     int tmmday     Day of month [1,31]
     int tmmon      Month of year [0,11]
     int tmyear     Years since 1900
     int tmwday     Day of week [0,6] (Sunday = 0)
     int tmyday     Day of year [0,365]
     int tmisdst    Daylight savings flag

     The value of tmisdst is positive if Daylight Saving Time is in
     effect, 0 if Daylight Saving Time is not in effect, and negative if
     the information is not available.

     This header defines the following symbolic names:

     NULL                Null pointer constant.

     CLKTCK             Number of clock ticks per second returned by the
                         times() function.

     CLOCKSPERSEC      A number used to convert the value returned by the
                         clock() function into seconds.

     The clockt, sizet and timet types are defined as described in
     <sys/types.h>.

     Although the value of CLOCKSPERSEC is required to be 1 million on
     all XSI-conformant systems (XSI = X/Open System Interface), it may be
     variable on other systems and it should not be assumed that
     CLOCKSPERSEC is a compile-time constant.

     The value of CLKTCK is currently the same as the value of
     sysconf(SCCLKTCK); however, new applications should call sysconf()
     because the CLKTCK macro will be withdrawn.

     The <time.h> header provides a declaration for getdateerr.








Page 1                       Reliant UNIX 5.44                Printed 11/98

time(5)                                                             time(5)

     The following are declared as functions and may also be defined as
     macros:

     char      *asctime(const struct tm *timeptr);
     clockt    clock(void);
     char      *ctime(const timet *clock);
     double     difftime(timet time1, timet time0);
     struct tm *getdate(const char *string);
     struct tm *gmtime(const timet *timer);
     struct tm *localtime(const timet *timer);
     timet     mktime(struct tm *timeptr);
     sizet     strftime(char *s, sizet maxsize, const char *format,
                         const struct tm *timptr);
     char      *strptime(const char *buf, const char *format,
                         struct tm *tm);
     timet     time(timet *tloc);
     void       tzset(void);

     The following are declared as variables:

     extern int      daylight;
     extern long int timezone;
     extern char    *tzname[];

APPLICATION USAGE
     The range [0,61] for tmsec allows for the occasional leap second or
     double leap second.

SEE ALSO
     utime(2), time(2), asctime(3C), clock(3C), ctime(3C), daylight(3C),
     difftime(3C), getdate(3C), gmtime(3C), localtime(3C), mktime(3C),
     strftime(3C), strptime(3C), sysconf(3C), timezone(3C), tzname(3C),
     tzset(3C), systime(5).





















Page 2                       Reliant UNIX 5.44                Printed 11/98

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026