Uploaded image for project: 'PDFBox'
  1. PDFBox
  2. PDFBOX-4544

COSWriter.doWriteHeader(COSDocument) should use the document specified as parameter

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 2.0.14
    • Fix Version/s: 2.0.16, 3.0.0 PDFBox
    • Component/s: Writing
    • Labels:
      None

      Description

      COSWriter.doWriteHeader(COSDocument) currently takes a COSDocument as a parameter and its javadoc specifies that this document is used to retrieve the header data from. Still, the implementation actually uses the property fdDocument or pdDocument to get the pdf version number. This is usually equivalent to using the passed document, but there may be cases where this violates the contract specified in the javadoc. Besides, using the passed doc results in slightly less verbose code.

        Attachments

          Activity

            People

            • Assignee:
              tilman Tilman Hausherr
              Reporter:
              Rahn2 Jonathan
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: