public class RawBody extends Body
This class is a pure implementation of Body, and does not provide any class specific operations.
| Modifier and Type | Class and Description |
|---|---|
static class |
RawBody.Factory |
CAN_INVALIDATE, contentType, CT_APP_OCTET_STREAM, CT_DEFAULT, CT_MULTIPART_FORM_DATA, CT_MULTIPART_RELATED, CT_TEXT_PLAIN, CT_TEXT_XML_UTF8, CT_XOP_APPLICATION_XML, PUSH_WRITE, REMOVE_XFER_ENCODING_ON_WRITE_DEPRECATED, RETAIN_XFER_ENCODING_ON_READ, WRITE_NO_CTE| Constructor and Description |
|---|
RawBody(com.vordel.mime.HeaderSet headers, com.vordel.mime.ContentType contentType) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
contentAvailable() |
long |
getContentLength(int flags)
Return the Content length of the body.
|
void |
parse(java.io.InputStream is)
Parse a body from a specific InputStream.
|
void |
purgeContent()
Bodies are purged() when they are no longer in use.
|
void |
writeContent(java.io.OutputStream ios, int flags)
Write the content of the body to the specified OutputStream This is similar to
Body.write(java.io.OutputStream, int), but does not include the headers for the body. |
bufferInput, create, dispose, fini, getContentEncoding, getContentId, getContentType, getHeaders, getInputStream, getParent, getSource, initSource, parse, registerFactory, setParent, sevenbit, willwrite, write
public RawBody(com.vordel.mime.HeaderSet headers,
com.vordel.mime.ContentType contentType)
public long getContentLength(int flags)
throws java.io.IOException
BodyNote that as the flags sent to the Body.write(java.io.OutputStream, int) method may affect the output, this method must be passed the same flags.
getContentLength in class Bodyjava.io.IOExceptionpublic boolean contentAvailable()
contentAvailable in class Body
public void parse(java.io.InputStream is)
throws java.io.IOException
BodyThis should be considered "private" to callers: it must be invoked via Body.parse()
parse in class Bodyjava.io.IOExceptionBody.parse()
public void writeContent(java.io.OutputStream ios,
int flags)
throws java.io.IOException
BodyBody.write(java.io.OutputStream, int), but does not include the headers for the body.writeContent in class Bodyjava.io.IOExceptionpublic void purgeContent()
BodypurgeContent in class Body
This documentation and all its contents and graphics, copyright � 1999 - 2011 Vordel