Class PRStream


@Deprecated public class PRStream extends PdfStream
Deprecated.
  • Field Details

    • reader

      protected PdfReader reader
      Deprecated.
    • offset

      protected int offset
      Deprecated.
    • length

      protected int length
      Deprecated.
    • objNum

      protected int objNum
      Deprecated.
    • objGen

      protected int objGen
      Deprecated.
  • Constructor Details

    • PRStream

      public PRStream(PRStream stream, PdfDictionary newDic)
      Deprecated.
    • PRStream

      public PRStream(PRStream stream, PdfDictionary newDic, PdfReader reader)
      Deprecated.
    • PRStream

      public PRStream(PdfReader reader, int offset)
      Deprecated.
    • PRStream

      public PRStream(PdfReader reader, byte[] conts)
      Deprecated.
    • PRStream

      public PRStream(PdfReader reader, byte[] conts, int compressionLevel)
      Deprecated.
      Creates a new PDF stream object that will replace a stream in a existing PDF file.
      Parameters:
      reader - the reader that holds the existing PDF
      conts - the new content
      compressionLevel - the compression level for the content
      Since:
      2.1.3 (replacing the existing constructor without param compressionLevel)
  • Method Details

    • setData

      public void setData(byte[] data, boolean compress)
      Deprecated.
      Sets the data associated with the stream, either compressed or uncompressed. Note that the data will never be compressed if Document.compress is set to false.
      Parameters:
      data - raw data, decrypted and uncompressed.
      compress - true if you want the stream to be compressed.
      Since:
      iText 2.1.1
    • setData

      public void setData(byte[] data, boolean compress, int compressionLevel)
      Deprecated.
      Sets the data associated with the stream, either compressed or uncompressed. Note that the data will never be compressed if Document.compress is set to false.
      Parameters:
      data - raw data, decrypted and uncompressed.
      compress - true if you want the stream to be compressed.
      compressionLevel - a value between -1 and 9 (ignored if compress == false)
      Since:
      iText 2.1.3
    • setData

      public void setData(byte[] data)
      Deprecated.
      Sets the data associated with the stream
      Parameters:
      data - raw data, decrypted and uncompressed.
    • getOffset

      public int getOffset()
      Deprecated.
    • getLength

      public int getLength()
      Deprecated.
    • setLength

      public void setLength(int length)
      Deprecated.
    • getReader

      public PdfReader getReader()
      Deprecated.
    • getBytes

      public byte[] getBytes()
      Deprecated.
      Description copied from class: PdfObject
      Gets the presentation of this object in a byte array
      Overrides:
      getBytes in class PdfObject
      Returns:
      a byte array
    • setObjNum

      public void setObjNum(int objNum, int objGen)
      Deprecated.
    • toPdf

      public void toPdf(PdfWriter writer, OutputStream os) throws IOException
      Deprecated.
      Description copied from class: PdfDictionary
      Writes the PDF representation of this PdfDictionary as an array of byte to the given OutputStream.
      Overrides:
      toPdf in class PdfStream
      Parameters:
      writer - for backwards compatibility
      os - the OutputStream to write the bytes to.
      Throws:
      IOException - on error
      See Also: