amazonka-core-1.3.2: Core data types and functionality for Amazonka libraries.

Copyright(c) 2013-2015 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityprovisional
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Network.AWS.Compat.Time

Description

 

Synopsis

Documentation

parseTime

Arguments

:: ParseTime t 
=> TimeLocale

Time locale.

-> String

Format string.

-> String

Input string.

-> Maybe t

The time value, or Nothing if the input could not be parsed using the given format.

Parses a time value given a format string. Supports the same %-codes as formatTime, including %-, %_ and %0 modifiers. Leading and trailing whitespace is accepted. Case is not significant. Some variations in the input are accepted:

%z
accepts any of -HHMM or -HH:MM.
%Z
accepts any string of letters, or any of the formats accepted by %z.
%0Y
accepts exactly four digits.
%0G
accepts exactly four digits.
%0C
accepts exactly two digits.
%0f
accepts exactly two digits.