java.lang.Object
org.htmlunit.http.ContentDispositionParser
Parser for the
Content-Disposition header.
- RFC 6266 (HTTP) and RFC 2183 (disposition type and parameters)
- RFC 8187 extended parameters (
filename*=UTF-8''...); supported charsets are UTF-8 and ISO-8859-1
The parser is lenient like the browsers are: parameter names are case-insensitive, white space around names and values is ignored, an unterminated quoted string ends at the end of the header. An extended value with a broken percent encoding is ignored (like Firefox does), so the plain parameter can be used as fallback.
- Author:
- Ronald Brill
-
Method Summary
Modifier and TypeMethodDescriptionstatic ContentDispositionParses the value of aContent-Dispositionheader.
-
Method Details
-
parse
Parses the value of aContent-Dispositionheader.- Parameters:
header- the header value- Returns:
- the parsed header or
nullif the given value isnull
-