strptime man page on IRIX

Man page or keyword search:  
man Server   31559 pages
apropos Keyword Search (all sections)
Output format
IRIX logo
[printable version]



strptime(3C)							  strptime(3C)

NAME
     strptime - date and time conversion

SYNOPSIS
     #include <time.h>

     char *strptime (const char *buf, const char *format, struct tm *tm);

DESCRIPTION
     strptime converts the character string pointed to by buf to values which
     are stored in the tm structure pointed to by tm, using the format
     specified by format.

     The format string consists of zero or more directives and ordinary
     characters.  Each directive is composed of one of the following: one or
     more white-space characters (as specified by isspace(); an ordinary
     character (neither % nor a white-space character);	 or a conversion
     specification. Each conversion specification is composed of a % character
     followed by a conversion character which specifies the replacement
     required. There must be white-space or other non-alphanumeric characters
     between any two conversion specifications. The following conversion
     specifications are supported:

     %%	       same as %
     %a	       is the day of week, using the locale's weekday names; either
	       the abbreviated or full name may be specified.
     %A	       is the same as %a.
     %b	       is the month, using the locale's month names; either the
	       abbreviated or full name may be specified.
     %B	       is the same as %b.
     %c	       is replaced by the locale's appropriate date and time
	       representation.
     %C	       is the century number [0,99]; leading zeros are permitted but
	       not required.
     %d	       day of month ( 01 - 31 ); leading zeroes are permitted but not
	       required.
     %D	       date as %m/%d/%y
     %e	       is the same as %d.
     %h	       is the same as %b.
     %H	       is the hour (24-hour clock) ( 00 - 23 ); leading zeroes are
	       permitted but not required.
     %I	       hour ( 01 - 12 )
     %j	       day number of year ( 001 - 366 )
     %m	       month number ( 01 - 12 )
     %M	       minute ( 00 - 59 )
     %n	       is any white space.
     %p	       locale's equivalent of either AM or PM
     %r	       time as %I:%M:%S %p [AM|PM]
     %R	       time as %H:%M
     %S	       seconds ( 00 - 61 ), allows for leap seconds

									Page 1

strptime(3C)							  strptime(3C)

     %t	       is any white space.
     %T	       time as %H:%M:%S
     %U	       week number of year ( 00 - 53 ), Sunday is the first day of
	       week 1
     %w	       weekday number ( 0 - 6 ), Sunday = 0
     %W	       week number of year ( 00 - 53 ), Monday is the first day of
	       week 1
     %x	       locale's appropriate date representation
     %X	       locale's appropriate time representation
     %y	       year within century ( 00 - 99 )
     %Y	       year as ccyy ( e.g. 1986)

     The difference between %U and %W lies in which day is counted as the
     first of the week.	 Week number 01 is the first week in January starting
     with a Sunday for %U or a Monday for %W.  Week number 00 contains those
     days before the first Sunday or Monday in January for %U and %W,
     respectively.

   Selecting the Output's Language
     By default, the output of strptime appears in U.S. English.  The user can
     request that the output of strptime be in a specific language by setting
     the locale for category LC_TIME in setlocale.

   Timezone
     The timezone is taken from the environment variable TZ [see ctime(3C) for
     a description of TZ].

RETURN VALUE
     Upon successful completion, strptime() returns a pointer to the character
     following the last character parsed.  Otherwise, a null pointer is
     returned.

FILES
     /usr/lib/locale/locale/LC_TIME - file containing locale-specific date and
     time information

SEE ALSO
     time(2), ctime(3C), strftime(3C), getenv(3C), setlocale(3C), timezone(4),
     environ(5).

									Page 2

[top]

List of man pages available for IRIX

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net