public class OwFileUpStream extends FilterInputStream
PartInputStream filters a ServletInputStream, providing access
to a single MIME part contained with in which ends with the boundary specified.
It uses buffering to provide performance.
Alfresco Workdesk
Copyright (c) Alfresco Software, Inc.
All rights reserved.
For licensing information read the license.txt file or
go to: http://wiki.alfresco.com
in| Constructor and Description |
|---|
OwFileUpStream(javax.servlet.ServletInputStream in_p,
String boundary_p)
Creates a
PartInputStream which stops at the specified
boundary from a ServletInputStream. |
| Modifier and Type | Method and Description |
|---|---|
int |
available()
Returns the number of bytes that can be read from this input stream without
blocking.
|
void |
close()
Closes this input stream and releases any system resources associated with the stream.
|
int |
read()
Reads the next byte of data from the InputStream.
|
int |
read(byte[] b_p)
Reads some number of bytes from the input stream and stores them into the
buffer array.
|
int |
read(byte[] b_p,
int off_p,
int len_p)
Read upto len bytes of data from inputstream into an array of bytes.
|
mark, markSupported, reset, skippublic OwFileUpStream(javax.servlet.ServletInputStream in_p,
String boundary_p)
throws IOException
PartInputStream which stops at the specified
boundary from a ServletInputStream.in_p - boundary_p - IOExceptionpublic int read()
throws IOException
read in class FilterInputStream-1 if the end of the stream is reached.IOException - if an input or output exception has occurred.public int read(byte[] b_p)
throws IOException
read in class FilterInputStreamb_p - the byte array buffer into which the data is read.IOExceptionpublic int read(byte[] b_p,
int off_p,
int len_p)
throws IOException
read in class FilterInputStreamb_p - the byte array buffer into which the data is read.off_p - int the start offset of the data.len_p - int the total number of bytes read into the buffer, or
-1 if there is no more data because the
end of the stream has been reachedIOException - if an I/O error occurs.public int available()
throws IOException
available in class FilterInputStreamIOException - if an I/O error occurs.public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class FilterInputStreamIOException - if an I/O error occurs.Copyright © 2014 Alfresco Business Solutions. All Rights Reserved.