public class MultipartRequestEntity extends Object implements RequestEntity
| Modifier and Type | Field and Description |
|---|---|
protected Part[] |
parts
The MIME parts as set by the constructor
|
| Constructor and Description |
|---|
MultipartRequestEntity(Part[] parts,
FluentCaseInsensitiveStringsMap requestHeaders)
Creates a new multipart entity containing the given parts.
|
| Modifier and Type | Method and Description |
|---|---|
static byte[] |
generateMultipartBoundary()
Generates a random multipart boundary string.
|
long |
getContentLength()
Gets the request entity's length.
|
String |
getContentType()
Gets the entity's content type.
|
protected byte[] |
getMultipartBoundary()
Returns the MIME boundary string that is used to demarcate boundaries of this part.
|
boolean |
isRepeatable()
Returns
true if all parts are repeatable, false otherwise. |
void |
writeRequest(OutputStream out)
Writes the request entity to the given stream.
|
protected Part[] parts
public MultipartRequestEntity(Part[] parts, FluentCaseInsensitiveStringsMap requestHeaders)
parts - The parts to include.public static byte[] generateMultipartBoundary()
protected byte[] getMultipartBoundary()
public boolean isRepeatable()
true if all parts are repeatable, false otherwise.isRepeatable in interface RequestEntityOutputStream more than once,
false otherwise.public void writeRequest(OutputStream out) throws IOException
RequestEntitywriteRequest in interface RequestEntityIOExceptionpublic long getContentLength()
RequestEntitygetContentLength in interface RequestEntitypublic String getContentType()
RequestEntitygetContentType in interface RequestEntityCopyright © 2013. All Rights Reserved.