DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH
 

wcsftime(S)


wcsftime -- convert data and time to wide character string

Syntax

cc . . . -lc

#include <wchar.h>

size_t wcsftime(wchar_t *wcs, size_t maxsize, const char *format, const struct tm *timptr);

Description

wcsftime(S) converts and formats the time values contained in the structure pointed to by timptr; it then places output wide-character codes into the array pointed to by wcs. The conversion and formatting are controlled by the character string format. If the output string would be over maxsize wide characters long, the content in the array is undefined.

This routine behaves as if strftime(S) generates a character string, and then mbstowcs(S) takes this string as its string input and places its output wide character string to wcs. The interpretation of format for wcsftime( ) is the same as that for strftime(S).

If copying takes place in overlapping memory blocks, the result is undefined.

Return values

wcsftime( ) returns the number of its output wide-character codes in the array pointed to by wcs. The terminating null wide-character code is not included in the number count. If the output wide character string (including the terminating null) is more than maxsize wide-characters long, zero is returned and the contents of the array are undefined.

See also

strftime(S), mbstowcs(S)

Standards conformance

wcsftime is conformant with:
X/Open CAE Specification, System Interfaces and Headers, Issue 4, 1992.
© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003