createFromCOS(COSBase base) Create a pd stream from either a regular COSStream on a COSArray of cos streams.
Parameters: base - Either a COSStream or COSArray.
Constructor. Reads all data from the input stream and embeds it into the
document, this will close the InputStream.
Parameters: doc - The document that will hold the stream. Parameters: str - The stream parameter. throws: IOException - If there is an error creating the stream in the document.
Constructor. Reads all data from the input stream and embeds it into the
document, this will close the InputStream.
Parameters: doc - The document that will hold the stream. Parameters: str - The stream parameter. Parameters: filtered - True if the stream already has a filter applied. throws: IOException - If there is an error creating the stream in the document.
Create a pd stream from either a regular COSStream on a COSArray of cos streams.
Parameters: base - Either a COSStream or COSArray. A PDStream or null if base is null. throws: IOException - If there is an error creating the PDStream.
Get the list of decode parameters. Each entry in the list will refer to
an entry in the filters list.
The list of decode parameters. throws: IOException - if there is an error retrieving the parameters.
This will get the file specification for this stream. This is only
required for external files.
The file specification. throws: IOException - If there is an error creating the file spec.
Get the list of decode parameters. Each entry in the list will refer to
an entry in the filters list.
The list of decode parameters. throws: IOException - if there is an error retrieving the parameters.
This will get the list of filters that are associated with this stream. Or
null if there are none.
A list of all encoding filters to apply to this stream.
This will get the list of filters that are associated with this stream. Or
null if there are none.
A list of all encoding filters to apply to this stream.
A convenience method to get this stream as a string. Uses
the default system encoding.
a String representation of this (input) stream, with theplatform default encoding. throws: IOException - if there is an error while converting the stream to a string.
This will get the length of the filtered/compressed stream. This is readonly in the
PD Model and will be managed by this class.
The length of the filtered stream.
This will get a stream with some filters applied but not others. This is useful
when doing images, ie filters = [flate,dct], we want to remove flate but leave dct
Parameters: stopFilters - A list of filters to stop decoding at. A stream with decoded data. throws: IOException - If there is an error processing the stream.