|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.http.entity.mime.content.AbstractContentBody
org.apache.http.entity.mime.content.StringBody
public class StringBody
Text body part backed by a byte array.
MultipartEntityBuilder| Constructor Summary | |
|---|---|
StringBody(String text)
Deprecated. (4.3) use StringBody(String, ContentType)
or MultipartEntityBuilder |
|
StringBody(String text,
Charset charset)
Deprecated. (4.3) use StringBody(String, ContentType)
or MultipartEntityBuilder |
|
StringBody(String text,
ContentType contentType)
|
|
StringBody(String text,
String mimeType,
Charset charset)
Deprecated. (4.3) use StringBody(String, ContentType)
or MultipartEntityBuilder |
|
| Method Summary | |
|---|---|
static StringBody |
create(String text)
Deprecated. (4.3) use StringBody(String, ContentType)
or MultipartEntityBuilder |
static StringBody |
create(String text,
Charset charset)
Deprecated. (4.3) use StringBody(String, ContentType)
or MultipartEntityBuilder |
static StringBody |
create(String text,
String mimeType,
Charset charset)
Deprecated. (4.3) use StringBody(String, ContentType)
or MultipartEntityBuilder |
long |
getContentLength()
Returns the body descriptors content-length. |
String |
getFilename()
|
Reader |
getReader()
|
String |
getTransferEncoding()
Returns the body descriptors transfer encoding. |
void |
writeTo(OutputStream out)
|
| Methods inherited from class org.apache.http.entity.mime.content.AbstractContentBody |
|---|
getCharset, getContentType, getMediaType, getMimeType, getSubType |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
@Deprecated
public StringBody(String text,
String mimeType,
Charset charset)
throws UnsupportedEncodingException
StringBody(String, ContentType)
or MultipartEntityBuilder
text - to be used for the body, not nullmimeType - the MIME type, not nullcharset - the character set, may be null, in which case the US-ASCII charset is used
UnsupportedEncodingException
IllegalArgumentException - if the text parameter is null
@Deprecated
public StringBody(String text,
Charset charset)
throws UnsupportedEncodingException
StringBody(String, ContentType)
or MultipartEntityBuilder
text - to be used for the body, not nullcharset - the character set, may be null, in which case the US-ASCII charset is used
UnsupportedEncodingException
IllegalArgumentException - if the text parameter is null
@Deprecated
public StringBody(String text)
throws UnsupportedEncodingException
StringBody(String, ContentType)
or MultipartEntityBuilder
text - to be used for the body, not null
UnsupportedEncodingException
IllegalArgumentException - if the text parameter is null
public StringBody(String text,
ContentType contentType)
| Method Detail |
|---|
@Deprecated
public static StringBody create(String text,
String mimeType,
Charset charset)
throws IllegalArgumentException
StringBody(String, ContentType)
or MultipartEntityBuilder
IllegalArgumentException
@Deprecated
public static StringBody create(String text,
Charset charset)
throws IllegalArgumentException
StringBody(String, ContentType)
or MultipartEntityBuilder
IllegalArgumentException
@Deprecated
public static StringBody create(String text)
throws IllegalArgumentException
StringBody(String, ContentType)
or MultipartEntityBuilder
IllegalArgumentExceptionpublic Reader getReader()
public void writeTo(OutputStream out)
throws IOException
IOExceptionpublic String getTransferEncoding()
ContentDescriptor
public long getContentLength()
ContentDescriptor
public String getFilename()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||