|
fop 1.1 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.fop.pdf.PDFObject
org.apache.fop.pdf.AbstractPDFStream
org.apache.fop.pdf.PDFStream
public class PDFStream
Class representing a PDF stream.
A derivative of the PDF Object, a PDF Stream has not only a dictionary but a stream of PDF commands. The stream of commands is where the real work is done, the dictionary just provides information like the stream length.
| Field Summary | |
|---|---|
protected StreamCache |
data
The stream of PDF commands |
| Fields inherited from class org.apache.fop.pdf.PDFObject |
|---|
log |
| Constructor Summary | |
|---|---|
PDFStream()
Create an empty stream object |
|
PDFStream(boolean encodeOnTheFly)
|
|
PDFStream(PDFDictionary dictionary)
|
|
PDFStream(PDFDictionary dictionary,
boolean encodeOnTheFly)
|
|
| Method Summary | |
|---|---|
void |
add(java.lang.String s)
Append data to the stream |
java.io.OutputStream |
getBufferOutputStream()
Returns an OutputStream that can be used to write to the buffer which is used to build up the PDF stream. |
java.io.Writer |
getBufferWriter()
Returns a Writer that writes to the OutputStream of the buffer. |
int |
getDataLength()
Returns the size of the content. |
protected int |
getSizeHint()
Returns a value that hints at the size of the encoded stream. |
int |
output(java.io.OutputStream stream)
Overload the base object method so we don't have to copy byte arrays around so much Write the PDF represention of this object |
protected void |
outputRawStreamData(java.io.OutputStream out)
Sends the raw stream data to the target OutputStream. |
void |
setData(byte[] data)
Used to set the contents of the PDF stream. |
| Methods inherited from class org.apache.fop.pdf.AbstractPDFStream |
|---|
encodeAndWriteStream, encodeStream, get, getDefaultFilterName, getDictionary, getFilterList, multipleFiltersAllowed, outputStreamData, populateStreamDict, prepareImplicitFilters, put, setDocument, setupFilterList |
| Methods inherited from class org.apache.fop.pdf.PDFObject |
|---|
contentEquals, encode, encodeBinaryToHexString, encodeString, encodeText, formatObject, getDocument, getDocumentSafely, getGeneration, getObjectID, getObjectNumber, getParent, hasObjectNumber, makeReference, outputInline, referencePDF, setObjectNumber, setParent, toPDF, toPDFString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected StreamCache data
| Constructor Detail |
|---|
public PDFStream()
public PDFStream(PDFDictionary dictionary)
public PDFStream(PDFDictionary dictionary,
boolean encodeOnTheFly)
public PDFStream(boolean encodeOnTheFly)
| Method Detail |
|---|
public void add(java.lang.String s)
s - the string of PDF to addpublic java.io.Writer getBufferWriter()
public java.io.OutputStream getBufferOutputStream()
throws java.io.IOException
java.io.IOException - In case of an I/O problem
public void setData(byte[] data)
throws java.io.IOException
data - the contents as a byte array
java.io.IOException - in case of an I/O problempublic int getDataLength()
protected int getSizeHint()
throws java.io.IOException
getSizeHint in class AbstractPDFStreamjava.io.IOException - in case of an I/O problem
protected void outputRawStreamData(java.io.OutputStream out)
throws java.io.IOException
outputRawStreamData in class AbstractPDFStreamout - OutputStream to write to
java.io.IOException - In case of an I/O problem
public int output(java.io.OutputStream stream)
throws java.io.IOException
output in class AbstractPDFStreamstream - the stream to write the PDF to
java.io.IOException - if there is an error writing to the stream
|
fop 1.1 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||