protected void unsetForbidRelease() { if (pdfObject != null) { pdfObject.clearState(PdfObject.FORBID_RELEASE); } }
/** * Marks object to be saved as indirect. * * @param document a document the indirect reference will belong to. * @return object itself. */ public PdfObject makeIndirect(PdfDocument document, PdfIndirectReference reference) { if (document == null || indirectReference != null) { return this; } if (document.getWriter() == null) { throw new PdfException(PdfException.ThereIsNoAssociatePdfWriterForMakingIndirects); } if (reference == null) { indirectReference = document.createNextIndirectReference(); indirectReference.setRefersTo(this); } else { indirectReference = reference; indirectReference.setRefersTo(this); } clearState(MUST_BE_INDIRECT); return this; }
writeToBody(pdfObject); indirectReference.setState(PdfObject.FLUSHED).clearState(PdfObject.MUST_BE_FLUSHED); switch (pdfObject.getType()) { case PdfObject.BOOLEAN: