Class ContentDisposition
- All Implemented Interfaces:
Serializable
,Cloneable
,Header
,NameValuePair
In a regular HTTP response, the Content-Disposition response header is a header indicating if the content is expected to be displayed inline in the browser, that is, as a Web page or as part of a Web page, or as an attachment, that is downloaded and saved locally.
Example
Content-Disposition: form-data; name="fieldName"; filename="filename.jpg"
RFC2616 Specification
The Expect request-header field is used to indicate that particular server behaviors are required by the client.content-disposition = "Content-Disposition" ":" disposition-type *( ";" disposition-parm ) disposition-type = "attachment" | disp-extension-token disposition-parm = filename-parm | disp-extension-parm filename-parm = "filename" "=" quoted-string disp-extension-token = token disp-extension-parm = token "=" ( token | quoted-string )
See Also:
-
Constructor Summary
ConstructorDescriptionContentDisposition
(String value) Constructor.ContentDisposition
(Supplier<StringRanges> value) Constructor with delayed value.ContentDisposition
(StringRanges value) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic ContentDisposition
Static creator.static ContentDisposition
of
(Supplier<StringRanges> value) Static creator with delayed value.static ContentDisposition
of
(StringRanges value) Static creator.Methods inherited from class org.apache.juneau.http.header.BasicStringRangesHeader
asStringRanges, getRange, getValue, match, of, of, of, orElse, toStringRanges
Methods inherited from class org.apache.juneau.http.header.BasicHeader
assertName, assertStringValue, asString, equals, equalsIgnoreCase, get, getElements, getName, hashCode, isNotEmpty, isPresent, of, of, orElse, toString
-
Constructor Details
-
ContentDisposition
Constructor.- Parameters:
value
- The header value.
Must be parsable byStringRanges.of(String)
.
Can benull .
-
ContentDisposition
Constructor.- Parameters:
value
- The header value.
Can benull .
-
ContentDisposition
Constructor with delayed value.Header value is re-evaluated on each call to
BasicStringRangesHeader.getValue()
.- Parameters:
value
- The supplier of the header value.
Can benull .
-
-
Method Details
-
of
Static creator.- Parameters:
value
- The header value.
Must be parsable byStringRanges.of(String)
.
Can benull .- Returns:
- A new header bean, or
null if the value isnull .
-
of
Static creator.- Parameters:
value
- The header value.
Can benull .- Returns:
- A new header bean, or
null if the value isnull .
-
of
Static creator with delayed value.Header value is re-evaluated on each call to
BasicStringRangesHeader.getValue()
.- Parameters:
value
- The supplier of the header value.
Can benull .- Returns:
- A new header bean, or
null if the value isnull .
-