PublicShow sourcehttp_request_value.pl -- Analyse values from HTTP request fields

The HTTP server parses some common fields in the request header into meaningful Prolog terms. Some fields however are not frequently used and rather hard to parse. This library is intended to grow in to a complete library for processing header fields.

To be done
- Clients will frequently use same the value for many of these fields. It is probably worthwhile to maintain a cache of translations.
Source http_parse_header_value(+Field, +Value, -Prolog) is semidet
Translate Value in a meaningful Prolog term. Field denotes the HTTP request field for which we do the translation. Supported fields are:
  • accept
Errors
- domain_error(http_request_field, Field) if this library is not prepared to handle this field (yet).