-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Parse and display time according to some RFCs (RFC3339, RFC2822, RFC822)
--   
--   Parse and display time according to some RFC's.
--   
--   Supported:
--   
--   <ul>
--   <li>RFC822 <a>http://www.ietf.org/rfc/rfc0822.txt</a></li>
--   <li>RFC2822 <a>http://www.ietf.org/rfc/rfc2822.txt</a></li>
--   <li>RFC3339 <a>http://www.ietf.org/rfc/rfc3339.txt</a></li>
--   </ul>
--   
--   Special thanks to Koral for all the suggestions and help in solving
--   some bugs.
@package timerep
@version 2.1.0.0


-- | Support for reading and displaying time in the format specified by the
--   RFC822 <a>http://www.ietf.org/rfc/rfc0822.txt</a> section 5.
--   
--   Example of usage:
--   
--   <pre>
--   import Data.Time.LocalTime
--   
--   showTime :: IO Text
--   showTime = formatTimeRFC822 &lt;$&gt; getZonedTime
--   
--   example1 = "Wed, 02 Oct 2002 13:00:00 GMT"
--   example2 = "Wed, 02 Oct 2002 13:00:00 +0100"
--   example3 = "Wed, 02 Oct 2002 13:00 +0100"
--   example4 = "02 Oct 2002 13:00 +0100"
--   example5 = "02 Oct 02 13:00 +0100"
--   examples = [example1, example2, example3, example4, example5]
--   
--   readAll = map parseTimeRFC822 examples
--   </pre>
module Data.Time.RFC822
formatTimeRFC822 :: TextualMonoid t => ZonedTime -> t
parseTimeRFC822 :: TextualMonoid t => t -> Maybe ZonedTime


-- | Support for reading and displaying time in the format specified by the
--   RFC3339 <a>http://www.ietf.org/rfc/rfc3339.txt</a>
--   
--   Example of usage:
--   
--   <pre>
--   import Data.Time.LocalTime
--   
--   showTime :: IO Text
--   showTime = formatTimeRFC3339 &lt;$&gt; getZonedTime
--   
--   example1 = "1985-04-12T23:20:50.52Z"
--   example2 = "1996-12-19T16:39:57-08:00"
--   example3 = "1990-12-31T23:59:60Z"
--   example4 = "1990-12-31T15:59:60-08:00"
--   example5 = "1937-01-01T12:00:27.87+00:20"
--   examples = [example1,example2,example3,example4,example5]
--   
--   readAll = map parseTimeRFC3339 examples
--   </pre>
module Data.Time.RFC3339
formatTimeRFC3339 :: TextualMonoid t => ZonedTime -> t
formatDateRFC3339 :: (TextualMonoid t, FormatTime time) => time -> t
parseTimeRFC3339 :: TextualMonoid t => t -> Maybe ZonedTime
parseDateRFC3339 :: TextualMonoid t => t -> Maybe Day


-- | Support for reading and displaying time in the format specified by the
--   RFC2822 <a>http://www.ietf.org/rfc/rfc2822.txt</a> section 3.3
--   
--   Example of usage:
--   
--   <pre>
--   import Data.Time.LocalTime
--   
--   showTime :: IO Text
--   showTime = getZonedTime &gt;&gt;= return . formatTimeRFC2822
--   
--   example1 = "Fri, 21 Nov 1997 09:55:06 -0600"
--   example2 = "Tue, 15 Nov 1994 12:45:26 GMT"
--   example3 = "Tue, 1 Jul 2003 10:52:37 +0200"
--   example4 = "Thu, 13 Feb 1969 23:32:54 -0330"
--   example5 = "Mon, 24 Nov 1997 14:22:01 -0800"
--   example6 = "Thu,          13\n     Feb\n  1969\n        23:32\n     -0330"
--   example7 = "Thu,          13\n     Feb\n  1969\n        23:32\n     -0330 (Newfoundland Time)"
--   example8 = "24 Nov 1997 14:22:01 -0800"
--   examples = [example1,example2,example3,example4,example5,example6,example7,example8]
--   
--   readAll = map parseTimeRFC2822 examples
--   </pre>
module Data.Time.RFC2822
formatTimeRFC2822 :: TextualMonoid t => ZonedTime -> t
parseTimeRFC2822 :: TextualMonoid t => t -> Maybe ZonedTime
