| Safe Haskell | None |
|---|---|
| Language | Haskell98 |
Web.Spock.Internal.Cookies
- data CookieSettings = CookieSettings {}
- data CookieEOL
- defaultCookieSettings :: CookieSettings
- parseCookies :: ByteString -> [(Text, Text)]
- generateCookieHeaderString :: Text -> Text -> CookieSettings -> UTCTime -> ByteString
- renderCookie :: SetCookie -> ByteString
Documentation
data CookieSettings Source #
Cookie settings
Constructors
| CookieSettings | |
Fields
| |
Setting cookie expiration
Constructors
| CookieValidUntil UTCTime | a point in time in UTC until the cookie is valid |
| CookieValidFor NominalDiffTime | a period (in seconds) for which the cookie is valid |
| CookieValidForSession | the cookie expires with the browser session |
| CookieValidForever | the cookie will have an expiration date in the far future |
defaultCookieSettings :: CookieSettings Source #
Default cookie settings, equals
CookieSettings
{ cs_EOL = CookieValidForSession
, cs_HTTPOnly = False
, cs_secure = False
, cs_domain = Nothing
, cs_path = Just "/"
}parseCookies :: ByteString -> [(Text, Text)] Source #
generateCookieHeaderString :: Text -> Text -> CookieSettings -> UTCTime -> ByteString Source #
renderCookie :: SetCookie -> ByteString Source #