|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.io.InputStream
com.infoengine.object.IeInputStream
com.infoengine.object.IeMultipartInputStream
public class IeMultipartInputStream
| Field Summary | |
|---|---|
static java.lang.String |
DEFAULT_BOUNDARY
|
static java.lang.String |
DEFAULT_EOF
|
static java.lang.String |
DEFAULT_EOL
|
| Constructor Summary | |
|---|---|
IeMultipartInputStream()
Use this constructor with setInputStream. |
|
IeMultipartInputStream(java.io.InputStream is)
This constructor will block until the mime header can be read off the input stream. |
|
IeMultipartInputStream(java.io.InputStream is,
java.lang.String contentType,
java.lang.String name,
java.lang.String filename)
This constructor creates a multipart stream from a non-multipart input stream. |
|
IeMultipartInputStream(javax.servlet.ServletRequest request)
This constructor sets the internal input stream to the request's input stream. |
|
| Method Summary | |
|---|---|
boolean |
eofRead()
|
java.lang.String |
getBoundary()
Returns the MIME boundary string that separates the content objects read from the stream. |
com.infoengine.object.ContentHeader |
getContentHeader()
Returns the last MIME content header object read from the input stream. |
int |
getContentLength()
|
java.lang.String |
getContentType()
Returns the MIME content type associated with the multipart input stream as a whole. |
java.lang.String |
getParameter(java.lang.String name)
Returns the value of a named parameter. |
java.util.Enumeration |
getParameterNames()
Returns the names of all parameters. |
java.util.Vector |
getParameterValues(java.lang.String name)
Returns the values of a named parameter. |
java.lang.String |
getRequestContentType()
Returns the MIME content type associated with the incoming request. |
java.util.Enumeration |
getXGroups()
returns an Enumeration of IeGroup objects found in the incoming MIME stream. |
boolean |
pushBackCalled()
Returns an indication of whether any MIME content headers have ever been pushed onto the internal stack. |
void |
pushBackHeader(com.infoengine.object.ContentHeader header)
Pushes a MIME content header object onto an internal stack. |
byte[] |
readBlob()
Reads the next BLOB on the input stream and returns it as a byte array. |
void |
readBlob(java.io.OutputStream os)
Reads the next BLOB on the input stream and writes it to an output stream. |
com.infoengine.object.ContentHeader |
readBlobInfo()
Reads the next MIME content header from the input stream. |
java.lang.String |
readBoundary()
Reads the next boundary line from the MIME input stream. |
com.infoengine.object.ContentHeader |
readHeader()
|
int |
readLine(byte[] bbuf)
Reads the next line from the MIME input stream into a byte array. |
int |
readLine(byte[] bbuf,
int start,
int max)
Reads the next line from the MIME input stream into a byte array, beginning at a specific index of the array and continuing until the end of the line is detected or a maximum number of bytes is read. |
IeRequest |
readRequest()
Reads the next content object from the input stream and parses it as an Info*Engine request object. |
java.lang.String |
readText()
Reads the next text object on the input stream and returns it as a String. |
void |
readText(java.io.OutputStream os)
Reads the next text object on the input stream and writes it to an output stream. |
IeCollection |
readVdb()
Reads the next content object from the input stream and parses it as an Info*Engine VDB object. |
void |
streamBlobs(java.io.OutputStream os)
Copies every BLOB on the input stream to an output stream. |
| Methods inherited from class com.infoengine.object.IeInputStream |
|---|
available, close, getInputStream, mark, markSupported, read, read, read, readLine, readLine, reset, setInputStream, skip |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String DEFAULT_BOUNDARY
public static final java.lang.String DEFAULT_EOF
public static final java.lang.String DEFAULT_EOL
| Constructor Detail |
|---|
public IeMultipartInputStream()
public IeMultipartInputStream(javax.servlet.ServletRequest request)
throws java.io.IOException
request - A servlet request object from which to obtain an
input stream containing a MIME multipart object.
java.io.IOException
public IeMultipartInputStream(java.io.InputStream is)
throws java.io.IOException
is - The input stream containing a MIME multipart object.
java.io.IOException
public IeMultipartInputStream(java.io.InputStream is,
java.lang.String contentType,
java.lang.String name,
java.lang.String filename)
throws java.io.IOException
is - The non-multipart input stream.contentType - The MIME content type to be associated with
the stream.name - The form variable name to be associated with the stream.filename - The file name to be associated with the stream.
java.io.IOException| Method Detail |
|---|
public java.util.Enumeration getXGroups()
public java.lang.String getParameter(java.lang.String name)
Parameters are available only when an IeMultipartInputStream is derived from a ServletRequest object (see the appropriate constructor above). Parameters are form variables submitted in an HTTP POST request with the MIME type multipart/form-data.
name - The name of the parameter.
public java.util.Vector getParameterValues(java.lang.String name)
Parameters are available only when an IeMultipartInputStream is derived from a ServletRequest object (see the appropriate constructor above). Parameters are form variables submitted in an HTTP POST request with the MIME type multipart/form-data.
name - The name of the parameter.
public java.util.Enumeration getParameterNames()
Parameters are available only when an IeMultipartInputStream is derived from a ServletRequest object (see the appropriate constructor above). Parameters are form variables submitted in an HTTP POST request with the MIME type multipart/form-data.
public com.infoengine.object.ContentHeader getContentHeader()
public IeRequest readRequest()
throws java.io.IOException,
IEException
java.io.IOException - if the next object on the input stream is not an
Info*Engine request object.
IEException
public IeCollection readVdb()
throws java.io.IOException,
IEException
java.io.IOException - if the next object on the input stream is not an
Info*Engine VDB object.
IEException
public void readBlob(java.io.OutputStream os)
throws java.io.IOException
os - The output stream on which to write the BLOB.
java.io.IOException - if the input stream can not be read
successfully.
public byte[] readBlob()
throws java.io.IOException
java.io.IOException - if the input stream can not be read
successfully.
public void readText(java.io.OutputStream os)
throws java.io.IOException
os - The output stream on which to write the text object.
java.io.IOException - if the input stream can not be read
successfully.
public java.lang.String readText()
throws java.io.IOException
java.io.IOException - if the input stream can not be read
successfully.
public com.infoengine.object.ContentHeader readBlobInfo()
throws java.io.IOException
java.io.IOException - if the input stream can not be read
successfully.
public void streamBlobs(java.io.OutputStream os)
throws java.io.IOException
os - The output stream on which to write all of the BLOB's
read from the input stream.
java.io.IOException - if the input stream can not be read or
the output stream can not be written
successfully.
public java.lang.String readBoundary()
throws java.io.IOException
java.io.IOException - if the input stream can not be read
successfully.
public int readLine(byte[] bbuf)
throws java.io.IOException
bbuf - The byte array in which to store the bytes read from the
input stream.
java.io.IOException - if the input stream can not be read
successfully.
public int readLine(byte[] bbuf,
int start,
int max)
throws java.io.IOException
bbuf - The byte array in which to store the bytes read from the
input stream.start - The index of the array in which to store the first byte.max - The maximum number of bytes to read.
java.io.IOException - if the input stream can not be read
successfully.public java.lang.String getRequestContentType()
public java.lang.String getContentType()
public java.lang.String getBoundary()
public void pushBackHeader(com.infoengine.object.ContentHeader header)
header - The content header to be pushed onto the stack.public boolean pushBackCalled()
public com.infoengine.object.ContentHeader readHeader()
throws java.io.IOException
java.io.IOExceptionpublic int getContentLength()
public boolean eofRead()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||