wai-extra-1.1.0: Provides some basic WAI handlers and middleware.

Safe HaskellSafe-Infered

Network.Wai.Parse

Contents

Description

Some helpers for parsing data out of a raw WAI Request.

Synopsis

Documentation

parseHttpAccept :: ByteString -> [ByteString]Source

Parse the HTTP accept string to determine supported content types.

lbsBackEnd :: BackEnd ByteStringSource

Store uploaded files in memory

tempFileBackEnd :: BackEnd FilePathSource

Save uploaded files on disk as temporary files

data BackEnd y Source

A destination for file data, with concrete implemtations provided by lbsBackEnd and tempFileBackEnd

Constructors

forall x . BackEnd 

Fields

initialize :: IO x
 
append :: x -> ByteString -> IO x
 
close :: x -> IO y
 
finalize :: y -> IO ()
 

data FileInfo c Source

Information on an uploaded file.

Instances

Eq c => Eq (FileInfo c) 
Show c => Show (FileInfo c) 

Deprecated

lbsSink :: BackEnd ByteStringSource

This function has been renamed to lbsBackEnd

tempFileSink :: BackEnd FilePathSource

This function has been renamed to tempFileBackEnd