Class ContentDisposition.Builder
java.lang.Object
io.helidon.http.ContentDisposition.Builder
- All Implemented Interfaces:
Builder<ContentDisposition.Builder, ContentDisposition>, Supplier<ContentDisposition>
- Enclosing class:
ContentDisposition
public static final class ContentDisposition.Builder
extends Object
implements Builder<ContentDisposition.Builder, ContentDisposition>
Fluent API builder for
ContentDisposition.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe form-data content disposition used byMediaTypes.MULTIPART_FORM_DATA. -
Method Summary
Modifier and TypeMethodDescriptionbuild()Build the instance from this builder.creationDate(ZonedDateTime date) Set the content dispositioncreation-dateparameter.Set the content dispositionfilenameparameter.Set the content dispositionmodification-dateparameter.Set the content dispositionnameparameter.Add a new content disposition header parameter.readDate(ZonedDateTime date) Set the content dispositionread-dateparameter.size(long size) Set the content dispositionsizeparameter.Set the content disposition type.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Builder
get, identity, updateModifier and TypeMethodDescriptiondefault ContentDispositionget()default ContentDisposition.Builderidentity()Instance of this builder as the correct type.default ContentDisposition.Builderupdate(Consumer<ContentDisposition.Builder> consumer) Update the builder in a fluent API way.
-
Field Details
-
TYPE_FORM_DATA
The form-data content disposition used byMediaTypes.MULTIPART_FORM_DATA.- See Also:
-
-
Method Details
-
build
Description copied from interface:BuilderBuild the instance from this builder.- Specified by:
buildin interfaceBuilder<ContentDisposition.Builder, ContentDisposition>- Returns:
- instance of the built type
-
type
Set the content disposition type. Defaults to "form-data".- Parameters:
type- content disposition type- Returns:
- updated builder
-
name
Set the content dispositionnameparameter.- Parameters:
name- control name- Returns:
- this builder
-
filename
Set the content dispositionfilenameparameter.- Parameters:
filename- filename parameter- Returns:
- this builder
-
creationDate
Set the content dispositioncreation-dateparameter.- Parameters:
date- date value- Returns:
- this builder
-
modificationDate
Set the content dispositionmodification-dateparameter.- Parameters:
date- date value- Returns:
- this builder
-
readDate
Set the content dispositionread-dateparameter.- Parameters:
date- date value- Returns:
- this builder
-
size
Set the content dispositionsizeparameter.- Parameters:
size- size value- Returns:
- this builder
-
parameter
Add a new content disposition header parameter.- Parameters:
name- parameter namevalue- parameter value- Returns:
- this builder
-