Mon, 01 Jul 2024 23:51:22 UTC | login

Information for RPM ghc-http-media-0.7.1.3-1.fc31.src.rpm

ID387270
Nameghc-http-media
Version0.7.1.3
Release1.fc31
Epoch
Archsrc
SummaryProcessing HTTP Content-Type and Accept headers
DescriptionThis library is intended to be a comprehensive solution to parsing and selecting quality-indexed values in HTTP headers. It is capable of parsing both media types and language parameters from the Accept and Content header families, and can be extended to match against other accept headers as well. Selecting the appropriate header value is achieved by comparing a list of server options against the quality-indexed values supplied by the client. In the following example, the Accept header is parsed and then matched against a list of server options to serve the appropriate media using 'mapAcceptMedia': > getHeader >>= maybe send406Error sendResourceWith . mapAcceptMedia > [ ("text/html", asHtml) > , ("application/json", asJson) > ] Similarly, the Content-Type header can be used to produce a parser for request bodies based on the given content type with 'mapContentMedia': > getContentType >>= maybe send415Error readRequestBodyWith . mapContentMedia > [ ("application/json", parseJson) > , ("text/plain", parseText) > ] The API is agnostic to your choice of server.
Build Time2019-07-26 04:59:09 GMT
Size25.46 KB
e7d35d04a4c2c11e57703dbfc7defd75
LicenseMIT
Buildrootf31-build-54544-28008
Provides No Provides
Obsoletes No Obsoletes
Conflicts No Conflicts
Requires
ghc-Cabal-devel
ghc-bytestring-devel
ghc-case-insensitive-devel
ghc-containers-devel
ghc-rpm-macros
ghc-utf8-string-devel
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
Recommends No Recommends
Suggests No Suggests
Supplements No Supplements
Enhances No Enhances
Files
1 through 2 of 2
Name ascending sort Size
ghc-http-media.spec3.86 KB
http-media-0.7.1.3.tar.gz15.41 KB
Component of No Buildroots