INTERNATIONAL VERSION
Page 1 (printed 6/20/89)
NL_CXTIME(S) UNIX System V NL_CXTIME(S)
NL_CXTIME(S) UNIX System V NL_CXTIME(S)
Name
nl_ascxtime, nl_cxtime - format date and time
Syntax
#include <time.h>
char *nl_cxtime(clock, format)
long *clock;
char *format;
char *nl_ascxtime(tm, format)
struct tm *tm;
char *format;
Description
The routines nl_ascxtime and nl_cxtime are provided as an
alternative interface to the ctime(S) routines, for programs
written to the X/OPEN Portability Guide standard.
They provide the same functions as the ctime(S) routines
ctime and asctime, except that a strftime(S) format string
is provided to determine the layout of the resulting string.
The X/OPEN Portability Guide permits the following field
descriptors only:
n insert a newline character
t insert a tab character
m month of year - 01 to 12
d day of month - 01 to 31
y last 2 digits of year - 00 to 99
D date as mm/dd/yy
H hour - 00 to 23
M minute - 00 to 59
S second - 00 to 59
T time as HH:MM:SS
j day of year - 001 to 366
w day of week - 0 to 6 (Sunday = 0)
a abbreviated weekday - e.g. Sun to Sat
h abbreviated month - e.g. Jan to Dec
r time in AM/PM notation
If format is the empty (zero length) string, the date and
time format (D_T_FMT) of the currently selected LC_TIME
locale is used.
The maximum length of the resultant string is defined by the
constant NL_TEXTMAX in the limits.h file.
See Also
limits(F), timtbl(M), ctime(S), nl_init(S)
Value Added
nl_ascxtime and nl_cxtime are extensions of AT&T System V
provided by the Santa Cruz Operation.
(printed 6/20/89)