úÎhõdê=      !"#$%&'()*+,-./0123456789:;< Safe-Infered , holds all the information necessary to run > bind to a sock and respond to TCP requests from the network. BThe TCP port the server will listen for incomming connections on. This => implements the actual functionality of the server. The input  and output of the =3 correspond to the input and output of the socket. NA function to transform an accept incomming connection into an iter and onum.  Most servers should just use defaultSocketAcceptor but this can be used for 5 special cases, e.g. accepting SSL connections with . :Must execute the monadic result. Servers operating in the > Monad can  use ?. $For convenience, a TCPServer in the > Monad with null defaults:  Port 0 (next availabel port)  Handler set to @  Acceptor set to   Request handler set to ? (noop) This acceptor creates an A and B using C and  D respectively. Runs a  in a loop. %Creates a simple HTTP server from an HTTPRequestHandler.  Creates a 2 that echoes each line from the client until EOF.  E    ESafe A F? monad in which requests can be handled. It keeps track of the  G3, the form parameters from the request body and an H used  to reply to the client. 7A request parameter from a form field in the HTTP body  Header of a  multipart/ form-data post Sets a the value for "_sess"$ in the cookie to the given string.  Removes the "_sess"! key-value pair from the cookie. LReturns the value of an Http Header from the request if it exists otherwise  I  Returns the G for the current request. )Returns the body of the current request. Set the list of s. Returns a list of all s.  Returns the ' corresponding to the specified key or I ' if one is not present in the request. Force get parameter value 2Get (maybe) paramater value and transform it with f          Safe!%Responds to the client with an empty 404 (Not Found) response. "(Replaces the HTTP status in the current H with the given  J. #Responds to the client with a 303, (Temporary Redirect) response to the given  path. $ Redirect "back" according to the "referer" header. %Responds to the client with a 200( (Success) response with the given body  and mime-type. !"#The path to redirect to $%(The mime-type of the response (commonly "text/html") The response body !"#$%%#$!"!"#$%Safe &An  ActionRoute either matches an G and returns a  corresponding   that responds to it, or I  signifying, no approriate   was found.  ActionRoutes can  be strung together with, e.g., K such that each will be  searched in turn until an   responding to the G is  found. (Like 0. but consumes the rest of the request for the  body )Runs an &#. If it satisfies the request, the  underlying   is returned, otherwise an   responding C with HTTP 404 (Not Found) is returned instead. Can be used at the ( top of a request handler, for example:   httpHandler :: Action b m () * httpHandler = runActionRoute $ mconcat [ ' routeTop $ routeAction homeAction 1 , routeMethod "POST" $ routeAction handleForm . , routeMethod "GET" $ routeAction showForm  ] BBut also can be nested inside of another action to created nested $ routes, or state dependant routes:   httpHandler :: Action b m () * httpHandler = runActionRoute $ mconcat [ ' routeTop $ routeAction homeAction @ , routeName "foo" $ routeAction $ runActionRoute $ mconcat [ 0 routeMethod "GET" $ runAction showForm 3 , routeMethod "POST" $ runAction handleForm  ]  ] or  handleForm = do  day <- lift $ getDayOfWeek  case mod day 2 of @ 0 -> runActionRoute $ routeName "stts" $ routeAction doRes ? 1 -> runActionRoute $ routeName "mwf" $ routeAction doRes *'Routes a specific directory name, like routeMap for a singleton  map. +@Matches any directory name, but additionally pushes it onto the  front of the L list in the G structure. This A allows the name to serve as a variable argument to the eventual  handling function. ,Match request with path "/". -&Match requests with the given method ("GET", "POST", etc). . Routes an   / Routes an  0 to the given URL pattern. Patterns can include 9 directories as well as variable patterns (prefixed with :) to be passed  into the   as extra !s. Some examples of URL patters:  /posts/:id  /posts/:id/new  /:date/posts/ :category/new 0Runs an   given an G and body. Returns the H  generated by the  . &'()*+,-./01M &'()*+,-./01 &')(0./*+,-1 &'()*+,-./01MSafe 2 The class RestController, allows a set of actions to be routed using  RESTful HTTP verbs. 3GET / 4GET /:id id' is passed in as the second parameter. 5GET /new 6POST / 7GET /:id/edit id' is passed in as the second parameter. 8PUT /:id id' is passed in as the second parameter. Since PUTA is not supported by many browsers, this action also responds to % requests containing the HTTP header X-HTTP-Method-Override: PUT ' regardless of the actual HTTP method (GET or POST) 9DELETE /:id id' is passed in as the second parameter. Since DELETEA is not supported by many browsers, this action also responds to % requests containing the HTTP header X-HTTP-Method-Override: DELETE ' regardless of the actual HTTP method (GET or POST) :Routes URLs under the given String to actions in a RestController. For  example    routeRestController posts myRestController will map the follwoing URLs:  GET /posts => myRestController# restIndex  POST /posts => myRestController# restCreate  GET /posts/:id => myRestController# restShow  GET /posts/:id/edit => myRestController# restEdit  GET /posts/:id/new => myRestController#restNew  DELETE /posts/:id => myRestController# restDestroy  PUT /posts/:id => myRestController# restUpdate 23456789: 23456789: 23456789:23456789:Safe;For  s where the body type is a N , parse the  body with 'parseParams\'' and prepend the result to the Action's  s <9Parse url encoded or form encoded paramters from an HTTP  body. ;<;<;<;< Safe2  !"#$%&'()*+,-./0123456789:;<O      !"#$%&'()*+,--./0123456789:;<=>?@ABCDEFGHIJKCDLCMNCDOCPQCPRSTUVCWXCWYIZ[CW\I]^CW_`abcditerio-server-0.3Data.IterIO.Server.TCPServerData.IterIO.Http.Support.Action"Data.IterIO.Http.Support.Responses Data.IterIO.Http.Support.Routing'Data.IterIO.Http.Support.RestControllerData.IterIO.Http.Support.UtilsData.IterIO.SSLiterSSLData.IterIO.Http.Support TCPServer serverPort serverHandlerserverAcceptorserverResultHandlerminimalTCPServerdefaultServerAcceptor runTCPServersimpleHttpServer echoServerAction ActionState actionReq actionResp actionParams actionBodyParamparamKey paramValue paramHeaders setSessiondestroySession requestHeader getHttpReqgetBody setParamsparamsparamparamVal paramValM respond404 respondStat redirectTo redirectBackrender ActionRoute runIterActionrunActionRoute routeNamerouteVarrouteTop routeMethod routeAction routePattern runAction routeFileSysRestController restIndexrestShowrestNew restCreaterestEdit restUpdate restDestroyrouteRestController parseParams parseParams' iterIO-0.2.2Data.IterIO.InumInumghc-prim GHC.TypesIObaseGHC.BaseidinumNopData.IterIO.IterIterOnumData.IterIO.ListLikehandleI enumHandle$fShowTCPServertransformers-0.2.2.0Control.Monad.Trans.State.LazyStateTData.IterIO.HttpHttpReqHttpResp Data.MaybeNothing HttpStatus Data.Monoidmappend reqPathParams$fMonoidActionRoutebytestring-0.9.2.1Data.ByteString.Lazy.Internal ByteString