>      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|} ~   Trustworthy Type alias for Creates a 200 (OK) / with the given content-type and resposne body6Helper to make responses with content-type "text/html"Creates a 200 (OK) ; with content-type "text/html" and the given resposne body Creates a 200 (OK) B with content-type "application/json" and the given resposne body Creates a 200 (OK) A with content-type "application/xml" and the given resposne body .Given a URL returns a 301 (Moved Permanently)  redirecting to that URL. &Given a URL returns a 303 (See Other)  redirecting to that URL. Returns a 400 (Bad Request) .'Returns a 401 (Authorization Required) 4 requiring basic authentication in the given realm.Returns a 403 (Forbidden) .Returns a 404 (Not Found) .Returns a 500 (Server Error) .         Trustworthy +357>LLike  , but with m as the underlying monadLike  , but with m as the underlying monad?The class of types into which query parameters may be convertedUThe ControllerT Monad is both a State-like monad which, when run, computes either a h or a result. Within the ControllerT Monad, the remainder of the computation can be short-circuited by ! ing with a .Extract the request,Modify the request for the given computation&Extract the application-specific state Convert the controller into an !Provide a response respond r >>= f === respond r"#Lift an application to a controller#!Matches on the hostname from the ,. The route only succeeds on exact matches.$Matches if the path is empty.!Note that this route checks that ] is empty, so it works as expected in nested contexts that have popped components from the  list.%)Matches on the HTTP request method (e.g. , , )&FMatches if the request's Content-Type exactly matches the given string'lRoutes the given URL pattern. Patterns can include directories as well as variable patterns (prefixed with :) to be added to  (see )) /posts/:id/posts/:id/new/:date/posts/:category/new(=Matches if the first directory in the path matches the given  ByteString)5Always matches if there is at least one directory in  but and adds a parameter to ] where the key is the first parameter and the value is the directory consumed from the path.*KLooks up the parameter name in the request's query string and returns the  Parseable value or .AFor example, for a request with query string: "?foo=bar&baz=7", queryParam "foo" would return  Just "bar", but queryParam "zap" would return Nothing.+Like *:, but throws an exception if the parameter is not present.,0Selects all values with the given parameter name-Like *1, but further processes the parameter value with read4. If that conversion fails, an exception is thrown..Like -:, but throws an exception if the parameter is not present./Like ,2, but further processes the parameter values with read8. If any read-conversion fails, an exception is thrown.11Returns the value of the given request header or + if it is not present in the HTTP request.2\Redirect back to the referer. If the referer header is not present redirect to root (i.e., /).3ZRedirect back to the referer. If the referer header is not present fallback on the given .6 !"#$%&'()*Parameter name+,-Parameter name.Parameter name/Parameter name0123Fallback response456789:;<=>?@ABCDEFG& !"#$%&'()*+,-./012345676GFEDCBA@?>= !"#$%&'()*+,<;:-./01234569872 !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFG Trustworthy35HTThe Controller Monad is both a State-like monad which, when run, computes either a g or a result. Within the Controller Monad, the remainder of the computation can be short-circuited by O ing with a .JExtract the requestK,Modify the request for the given computationL&Extract the application-specific stateNConvert the controller into an OProvide a response respond r >>= f === respond rP!Matches on the hostname from the ,. The route only succeeds on exact matches.QMatches if the path is empty.!Note that this route checks that ] is empty, so it works as expected in nested contexts that have popped components from the  list.R)Matches on the HTTP request method (e.g. , , )SFMatches if the request's Content-Type exactly matches the given stringTlRoutes the given URL pattern. Patterns can include directories as well as variable patterns (prefixed with :) to be added to  (see V) /posts/:id/posts/:id/new/:date/posts/:category/newU=Matches if the first directory in the path matches the given  ByteStringV5Always matches if there is at least one directory in  but and adds a parameter to ] where the key is the first parameter and the value is the directory consumed from the path.WKLooks up the parameter name in the request's query string and returns the  Parseable value or .AFor example, for a request with query string: "?foo=bar&baz=7", queryParam "foo" would return  Just "bar", but queryParam "zap" would return Nothing.XLike W:, but throws an exception if the parameter is not present.Y0Selects all values with the given parameter nameZLike W1, but further processes the parameter value with read4. If that conversion fails, an exception is thrown.[Like Z:, but throws an exception if the parameter is not present.\Like Y2, but further processes the parameter values with read8. If any read-conversion fails, an exception is thrown.]?Parses a HTML form from the request body. It returns a list of s as well as a list of )s, which are pairs mapping the name of a file form field to a ? pointing to a temporary file with the contents of the upload. 2 myControllerT = do (prms, files) <- parseForm let mPicFile = lookup "profile_pic" files case mPicFile of Just (picFile) -> do sourceFile (fileContent picFile) $$ sinkFile ("images/" ++ (fileName picFile)) respond $ redirectTo "/" Nothing -> redirectBack ^/Reads and returns the body of the HTTP request._1Returns the value of the given request header or + if it is not present in the HTTP request.`\Redirect back to the referer. If the referer header is not present redirect to root (i.e., /).aZRedirect back to the referer. If the referer header is not present fallback on the given .HIJKLMNOPQRSTUVWParameter nameXYZParameter name[Parameter name\Parameter name]^_`aFallback responseHIJKLMNOPQRSTUVWXYZ[\]^_`aHNLMJKO_PQRSTUVWXYZ[\]`a^IHIJKLMNOPQRSTUVWXYZ[\]^_`aSafebcdebcdebcdebcdeNoneffffNonegAn g authenticates a # and, if successful, forwards the  to the  Routeable.hAn gV that uses HTTP basic authentication to authenticate a request in a particular realm.i Wraps an gg to take a simpler authentication function (that just just takes a username and password, and returns  or +). It also adds an "X-User" header to the Y with the authenticated user's name (the first argument to the authentication function).jA Route that uses HTTP basic authentication to authenticate a request for a realm with the given username ans password. The request is rewritten with an 'X-User'O header containing the authenticated username before being passed to the next Route.ghijRealmUsernamePasswordghijghjighij Trustworthy Helper methodk/Matches the GET method on the given URL patternl0Matches the POST method on the given URL patternm/Matches the PUT method on the given URL patternn2Matches the DELETE method on the given URL patterno3Matches the OPTIONS method on the given URL patternklmnoklmnoklmnoklmno Trustworthy17 q The layout to use by default. Layouts are just templates that embed views. They are rendered with the a global object containing the rendered view in the "yield" field, and the object the view was rendered with in the "page" field. By default, no template is used.r*The directory to look for views passed to y. This defaults to "views", so render "index.html.tmpl" ... 9will look for a view template in "views/index.html.tmpl".sHA map of pure functions that can be called from within a template. See  and  for details.t@Function to use to get a template. By default, it looks in the r for the given file name and compiles the file into a template. This can be overriden to, for example, cache compiled templates in memory.uThe  passed to a layout given the rendered view template and the value originally passed to the view template. By default, produces an m with "yield", containing the rendered view, and "page", containing the value originally passed to the view.w;Render a view using the layout named by the first argument.xSame as w# but uses already compiled layouts.yiRenders a view template with the default layout and a global used to evaluate variables in the template.zSame as y but without a template.pqrstuvwxyTemplate to renderAeson  to pass to the templatezTemplate to renderAeson  to pass to the template{|pqrstuvwxyz{|pqrstuyzwx{|v pqrstuvwxyz{|  Trustworthy35 5Monad used to encode a REST controller incrementally.~&Type used to encode a REST controller.Default state, returns 404 for all verbs.GET /POST / GET /:id/editGET /newGET /:idPUT /:id DELETE /:id}~}~~} }~  Trustworthy[ HIJKLMNOPQRSTUVWXYZ[\]^_`abcdef       !"#$%%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRST'()*+,-/0123456789:;UV=>?WXYZ[\]^_`abcdefghijklmnopq r s s t u v w x y z { | } ~  c  simpl_5cHmgFRZUTTDSHVfXPzguNWeb.Simple.TemplatesWeb.Simple.ResponsesWeb.Simple.Controller.TransWeb.Simple.ControllerWeb.Simple.Controller.ExceptionWeb.Simple.StaticWeb.Simple.Auth Web.FrankWeb.REST Web.Simplesimpl_C3x32SKv8TTJbYBiuj4N9YWeb.Simple.Templates.TypescallFunction toFunction ToFunction FunctionMapunord_GEo5atLhXsqD6lKQtRnTupData.HashMap.StrictfromListokokHtmlokJsonokXmlmovedTo redirectTo badRequestrequireBasicAuth forbiddennotFound serverErrorControllerExceptionSimpleMiddlewareSimpleApplication Parseableparse ControllerT runController hoistEitherrequest localRequestcontrollerStateputState controllerApprespondfromApp routeHostrouteTop routeMethod routeAccept routePattern routeNamerouteVar queryParam queryParam' queryParamsreadQueryParamreadQueryParam'readQueryParamsreadParamValue requestHeader redirectBackredirectBackOrguardguardMguardReqerr$fExceptionControllerException$fShowControllerException$fParseableText $fParseable[]$fParseableByteString$fMonadBaseControlmControllerT$fMonadBasemControllerT$fMonadIOControllerT$fMonadReaderRequestControllerT$fMonadStatesControllerT$fMonadTransControllerT$fMonadPlusControllerT$fAlternativeControllerT$fMonadControllerT$fApplicativeControllerT$fFunctorControllerT Controller parseFormbody onExceptionfinallybrackethandle serveStatic AuthRouterbasicAuthRouteauthRewriteReq basicAuthgetpostputdeleteoptions HasTemplates defaultLayout viewDirectory functionMap getTemplate layoutObjectdefaultLayoutObject renderLayoutrenderLayoutTmplrender renderPlaindefaultGetTemplatedefaultFunctionMapRESTControllerREST restIndexrestShow restCreate restUpdate restDeleterestEditrestNewrest routeRESTindexcreateeditnewshowupdate ContentTypebytes_6elQVSg5cWdFrvRnfxTUrHData.ByteString.Internal ByteStringwai_GaIGwfjnVnv3YsG5g6Gu74Network.Wai.InternalResponsemkHtmlResponse Network.Wai ApplicationRequestpathInfohttpt_K5bvT12P71qJPccnLMsPeJNetwork.HTTP.Types.MethodGETPOSTPUT queryStringbaseGHC.BaseNothingwaiex_Fiu2mLZgA59Gv1alNmD2wqNetwork.Wai.ParseParamFileFileInfoghc-prim GHC.TypesTrueFalse frankMethodaeson_HlhjT2iot3uC3gQEbzJErCData.Aeson.Types.InternalValueObject valueLength valueNullRESTControllerM defaultRESTlazyRequestBodystrictRequestBody ifRequestmodifyResponsedefaultRequestmapResponseHeadersresponseToStreamresponseHeadersresponseStatus responseRawresponseStream responseLBSresponseBuilder responseFile MiddlewarerequestHeaderUserAgentrequestHeaderRefererrequestHeaderRangerequestHeaderHostrequestBodyLengthvault requestBody remoteHostisSecurerequestHeadersrawQueryString rawPathInfo httpVersion requestMethod StreamingBody KnownLength ChunkedBodyRequestBodyLengthfilePartFileSizefilePartByteCountfilePartOffsetFilePartResponseReceived