Class MultiPartConfig.Builder
java.lang.Object
org.eclipse.jetty.http.MultiPartConfig.Builder
- Enclosing class:
MultiPartConfig
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()complianceMode(MultiPartCompliance complianceMode) maxHeadersSize(int maxHeadersSize) maxMemoryPartSize(long maxMemoryPartSize) Sets the maximum size of a part in memory, after which it will be written as a file.maxParts(int maxParts) maxPartSize(long maxPartSize) maxSize(long maxSize) useFilesForPartsWithoutFileName(Boolean useFilesForPartsWithoutFileName) violationListener(ComplianceViolation.Listener violationListener)
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
location
- Parameters:
location- the directory where parts will be saved as files.
-
maxParts
- Parameters:
maxParts- the maximum number of parts that can be parsed from the multipart content, or -1 for unlimited.
-
maxSize
- Returns:
- the maximum size in bytes of the whole multipart content, or -1 for unlimited.
-
maxPartSize
- Returns:
- the maximum part size in bytes, or -1 for unlimited.
-
maxMemoryPartSize
Sets the maximum size of a part in memory, after which it will be written as a file.
Use value
0to always write the part to disk.Use value
-1to never write the part to disk.- Parameters:
maxMemoryPartSize- the maximum part size which can be held in memory.
-
maxHeadersSize
- Parameters:
maxHeadersSize- the max length of aMultiPart.Partheaders, in bytes, or -1 for unlimited length.
-
useFilesForPartsWithoutFileName
public MultiPartConfig.Builder useFilesForPartsWithoutFileName(Boolean useFilesForPartsWithoutFileName) - Parameters:
useFilesForPartsWithoutFileName- whether parts without a fileName may be stored as files.
-
complianceMode
- Parameters:
complianceMode- the compliance mode.
-
violationListener
- Parameters:
violationListener- the compliance violation listener.
-
build
-