public class StringPart extends PartBase
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_CHARSET
Default charset of string parameters
|
static String |
DEFAULT_CONTENT_TYPE
Default content encoding of string parameters.
|
static String |
DEFAULT_TRANSFER_ENCODING
Default transfer encoding of string parameters
|
Constructor and Description |
---|
StringPart(String name,
String value)
Constructor.
|
StringPart(String name,
String value,
String charset)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
setCharSet(String charSet)
Sets the character encoding.
|
getCharSet, getContentType, getName, getTransferEncoding, setContentType, setName, setTransferEncoding
getBoundary, getLengthOfParts, getLengthOfParts, isRepeatable, length, send, sendParts, sendParts, toString
public static final String DEFAULT_CONTENT_TYPE
public static final String DEFAULT_CHARSET
public static final String DEFAULT_TRANSFER_ENCODING
public StringPart(String name, String value, String charset)
name
- The name of the partvalue
- the string to postcharset
- the charset to be used to encode the string, if null
the default
is usedpublic void setCharSet(String charSet)
PartBase
setCharSet
in class PartBase
charSet
- the character encoding, or null
to exclude the character
encoding headerCopyright © 2010 - 2020 Adobe. All Rights Reserved