include "tws.h" ^struct tws *dlocaltime( clock );~^/* local clock into tws */ long *clock; ^struct tws *gmtime( clock );~^/* GMT clock into tws */ long *clock; ^char *dtime( clock );~^/* clock into string */ long *clock; ^long twclock( t );~^/* tws into clock */ struct tws *t; ^long twjuliandate( t );~^/* tws into Julian day number */ struct tws *t; ^struct tws *dparsetime( str );~^/* string into tws */ char *str; ^char *dctime( t );~^/* tws into string */ struct tws *t; ^char *dasctime( t, flags );~^/* tws into string */ struct tws *t; int flags; ^char *dtimezone( offset, flags );~^/* timezone into string */ int offset, flags; ^char *dtwszone( t );~^/* tws's timezone into string */ struct tws *t; ^char *dtimemow( );~^/* current time into string */ ^struct tws *dtwstime( );~^/* current time into tws */ ^void twscopy( tot, fromt );~^/* copy a tws */ struct tws *tot, *fromt; ^int twsort( t1, t2 );~^/* compare two tws's */ struct tws *t1, *t2; ^long twsubtract( t1, t2 );~^/* seconds between t2 and t1 */ struct tws *t1, *t2;
Most of the routines do not use the Unix* "clock" time format, and therefore are not limited to dates after 01 January 1970. In particular, twsubtract() lets you subtract two dates without converting them to "clock" form.
The basic Unix* time format (clock) only goes back to 1970, limiting applications somewhat.