|
Generated by JDiff |
||||||||
PREV PACKAGE NEXT PACKAGE FRAMES NO FRAMES |
This file contains all the changes in documentation in the packagecom.itextpdf.kernel.pdf
as colored differences. Deletions are shownlike this, and additions are shown like this.
If no deletions or additions are shown in an entry, the HTML tags will be what has changed. The new HTML tags are shown in the differences. If no documentation existed, and then some was added in a later version, this change is noted in the appropriate class pages of differences, but the change is not shown on this page. Only changes in existing text are shown here. Similarly, documentation which was inherited from another class or interface is not shown here.
Note that an HTML error in the new documentation may cause the display of other documentation changes to be presented incorrectly. For instance, failure to close a tag will cause all subsequent paragraphs to be displayed differently.
This method gets Names tree from the catalog. @param treeType type of the tree (Dests, AP, EmbeddedFiles etc).Class PdfCatalog, PdfOCProperties getOCProperties(boolean)@return returns PdfNameTree
Use this method to get the Optional Content Properties Dictionary. Note that if you call this method, then the PdfDictionary with OCProperties will be generated from PdfOCProperties object right before closing the PdfDocument, so if you want to make low-level changes in Pdf structures themselves (PdfArray, PdfDictionary, etc),Class PdfCatalog, PdfNumTree getPageLabelsTree(boolean)then you should address directly those objects, e.g.:PdfCatalog pdfCatalog = pdfDoc.getCatalog(); PdfDictionary ocProps = pdfCatalog.getAsDictionary(PdfName.OCProperties); // manipulate with ocProps.
Also note that this method is implicitly called when creating a new PdfLayer instance, so you should either use hi-level logic of operating with layers, or manipulate low-level Pdf objects by yourself. @param createIfNotExists true to create new /OCProperties entry in catalog if not exists, false to return null if /OCProperties entry in catalog is not present.@return the Optional Content Properties Dictionary
This method returns the NumberTree of Page Labels @param createIfNotExists defines whether the NumberTree of Page Labels should be created if it didn't existClass PdfCatalog, PdfCatalog put(PdfName, PdfObject)beforebefore @return returns PdfNumTree
Add key and value to PdfCatalog dictionary. @param key the dictionary key corresponding with the PDF object @param value the value ofClass PdfCatalog, PdfCatalog remove(PdfName)keykey @return the key and value
Remove key from catalog dictionary. @param key the dictionary key corresponding with the PDFClass PdfCatalog, PdfCatalog setAdditionalAction(PdfName, PdfAction)objectobject @return the key
The actions that shall be taken in response to various trigger events affecting the document as a whole. See ISO 32000-1, Table 28 # Entries in the catalog dictionary. @param key the key of which the associated value needs to be returned @param action instance of PdfAction.Class PdfCatalog, PdfCatalog setCollection(PdfCollection)@return additional action
Sets collection dictionary that a conforming reader shall use to enhance the presentation of file attachments stored in the PDF document. @param collection dictionaryClass PdfCatalog, PdfCatalog setOpenAction(PdfAction)@return PdfCatalog instance with applied collection dictionary
A value specifying an action that shall be performed when the document is opened. See ISO 32000-1, Table 28 # Entries in the catalog dictionary. @param action instance of PdfAction.Class PdfCatalog, PdfCatalog setOpenAction(PdfDestination)@return action
A value specifying a destination that shall be displayed when the document is opened. See ISO 32000-1, Table 28 # Entries in the catalog dictionary. @param destination instance of PdfDestination.Class PdfCatalog, PdfCatalog setPageLayout(PdfName)@return destination
This method sets a page layout of the document @param pageLayout page layout of theClass PdfCatalog, PdfCatalog setPageMode(PdfName)documentdocument @return PdfCatalog instance with applied page layout
This method sets a page mode of the document.Class PdfCatalog, PdfCatalog setViewerPreferences(PdfViewerPreferences)
Valid values are: {@code PdfName.UseNone}, {@code PdfName.UseOutlines}, {@code PdfName.UseThumbs}, {@code PdfName.FullScreen}, {@code PdfName.UseOC}, {@code PdfName.UseAttachments}. @param pageMode page mode.@return current instance of PdfCatalog
This method sets the document viewer preferences, specifying the way the document shall be displayed on the screen @param preferences document's viewer preferences@return PdfCatalog instance with applied viewer preferences
Returns the value associated to this key as a PdfDictionary. If the value isn't a PdfDictionary, null is returned. @param key the key of which the associated value needs to be returned @return PdfDictionary associated with this key
Open PDF document in reading mode. @param reader PDF reader. @param properties document propertiesClass PdfDocument, constructor PdfDocument(PdfWriter, DocumentProperties)
Open PDF document in writing mode. Document has no pages when initialized. @param writer PDF writer @param properties document propertiesClass PdfDocument, void addAssociatedFile(String, PdfFileSpec)
Adds file associated with PDF document as a whole and identifies the relationship between them.Class PdfDocument, PdfPage addNewPage(PageSize)Associated files may be used in Pdf/A-3 and Pdf 2.0 documents. The method is very similar to PdfDocument.addFileAttachment(String, PdfFileSpec). However, besides adding file description to Names tree, it adds file to array value of the AF key in the
documentdocument catalog.For associated files their associated file specification dictionaries shall include the AFRelationship key @param description the file description @param fs file specification dictionary of associated
filefile @see PdfDocument#addFileAttachment(String, PdfFileSpec)
Creates and adds new page with the specified page size. @param pageSize page size of the newClass PdfDocument, PdfPage addNewPage(int)pagepage @return added page
Creates and inserts new page to the document. @param index position to addPage pageClass PdfDocument, PdfPage addNewPage(int, PageSize)toto @return insertedpagepage @throws PdfException in case {@code page} is flushed
Creates and inserts new page to the document. @param index position to addPage page to @param pageSize page size of the newClass PdfDocument, void addOutputIntent(PdfOutputIntent)pagepage @return insertedpagepage @throws PdfException in case {@code page} is flushed
Adds PdfOutputIntent that shall specify the colour characteristics of output devices on which the document might be rendered. @param outputIntent PdfOutputIntent to add.Class PdfDocument, PdfPage addPage(PdfPage)@see PdfOutputIntent
Adds page to the end of document. @param page page to add.Class PdfDocument, PdfPage addPage(int, PdfPage)@return added page.@throws PdfException in case {@code page} is flushed
Inserts page to the document. @param index position to addPage page to @param page page toClass PdfDocument, void checkIsoConformance(Object, IsoKey, PdfResources, PdfStream)addPageaddPage @return insertedpagepage @throws PdfException in case {@code page} is flushed
Checks whether PDF document conforms a specific standard. Shall be override. @param obj an object to conform. @param key type of object to conform. @param resources PdfResources associated with an object to check. @param contentStream current content streamClass PdfDocument, List
Copies a range of pages from current document to {@code toDocument} appending copied pages to the end. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, ListIf outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pagesToCopy list of pages to be copied. @param toDocument a document to copy pages to.
@return list of copied pages
Copies a range of pages from current document to {@code toDocument} appending copied pages to the end. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, ListIf outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pagesToCopy list of pages to be copied. @param toDocument a document to copy pages to. @param copier a copier which bears a special copy logic. May be null. It is recommended to use the same instance of IPdfPageExtraCopier for the same output document.
@return list of copied pages
Copies a range of pages from current document to {@code toDocument}. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, ListIf outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pagesToCopy list of pages to be copied. @param toDocument a document to copy pages to. @param insertBeforePage a position where to insert copied pages.
@return list of new copied pages
Copies a range of pages from current document to {@code toDocument}. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, ListIf outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pagesToCopy list of pages to be copied. @param toDocument a document to copy pages to. @param insertBeforePage a position where to insert copied pages. @param copier a copier which bears a special copy logic. May be null. It is recommended to use the same instance of IPdfPageExtraCopier for the same output document.
@return list of new copied pages
Copies a range of pages from current document to {@code toDocument} appending copied pages to the end. This range is inclusive, both {@code page} and {@code pageTo} are included in list of copied pages. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, ListIf outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pageFrom 1-based start of the range of pages to be copied. @param pageTo 1-based end (inclusive) of the range of pages to be copied. This page is included in list
ofof copied pages. @param toDocument a document to copy pages to.@return list of new copied pages
Copies a range of pages from current document to {@code toDocument} appending copied pages to the end. This range is inclusive, both {@code page} and {@code pageTo} are included in list of copied pages. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, ListIf outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pageFrom 1-based start of the range of pages to be copied. @param pageTo 1-based end (inclusive) of the range of pages to be copied. This page is included in list
ofof copied pages. @param toDocument a document to copy pages to. @param copier a copier which bears a special copy logic. May be null. It is recommended to use the same instance of IPdfPageExtraCopier for the same output document.@return list of new copied pages.
Copies a range of pages from current document to {@code toDocument}. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, ListIf outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pageFrom start of the range of pages to be copied. @param pageTo end of the range of pages to be copied. @param toDocument a document to copy pages to. @param insertBeforePage a position where to insert copied pages.
@return list of copied pages
Copies a range of pages from current document to {@code toDocument}. This range is inclusive, both {@code page} and {@code pageTo} are included in list of copied pages. Use this method if you want to copy pages across tagged documents. This will keep resultant PDF structure consistent.Class PdfDocument, PdfFont findFont(String, String)If outlines destination names are the same in different documents, all such outlines will lead to a single location in the resultant document. In this case iText will log a warning. This can be avoided by renaming destinations names in the source document. @param pageFrom 1-based start of the range of pages to be copied. @param pageTo 1-based end (inclusive) of the range of pages to be copied. This page is included in
listlist of copied pages. @param toDocument a document to copy pages to. @param insertBeforePage a position where to insert copied pages. @param copier a copier which bears a special copy logic. May be null. It is recommended to use the same instance of IPdfPageExtraCopier for the same output document.@return list of new copied pages
Find PdfFont from loaded fonts with corresponding fontProgram and encoding or CMAP. @param fontProgram a font name or path to a font program @param encoding an encoding or CMAP @return the font instance, or null if font wasn't foundClass PdfDocument, void flushCopiedObjects(PdfDocument)
Flush all copied objects and remove them from copied cache.Class PdfDocument, void flushObject(PdfObject, boolean)Note, if you will copy objects from the same document, duplicated objects will be created. That's why usually this method is meant to be used when all copying from source document is finished. For other cases one can also consider other flushing mechanisms, e.g. pages-based flushing.
@param sourceDoc source document
Flush an object. @param pdfObject object to flush. @param canBeInObjStm indicates whether object can be placed into object stream.Class PdfDocument, PdfString getModifiedDocumentId()@throws IOException on error.
Gets modified documentClass PdfDocument, PdfString getOriginalDocumentId()ididIn order to set modifiedDocumentId WriterProperties.setModifiedDocumentId should be used @return modified document id
Gets original documentClass PdfDocument, PdfOutline getOutlines(boolean)ididIn order to set originalDocumentId WriterProperties.setInitialDocumentId should be used @return original dccument id
This method returns a complete outline tree of the whole document. @param updateOutlines if the flag is {@code true}, the method reads the whole document and creates outline tree. If the flag is {@code false}, the method gets cached outline tree (if it was cached via calling getOutlines method before).Class PdfDocument, PdfPage getPage(PdfDictionary)@return fully initialize PdfOutline object.
Gets the PdfPage instance by PdfDictionary. @param pageDictionary PdfDictionary that present page.Class PdfDocument, PdfPage getPage(int)@return page by PdfDictionary.
Gets the page by page number. @param pageNum page number.Class PdfDocument, int getPageNumber(PdfDictionary)@return page by page number. may return {@code null} in case the page tree is broken
Gets page number by PdfDictionary. @param pageDictionary PdfDictionary that present page.Class PdfDocument, int getPageNumber(PdfPage)@return page number by PdfDictionary.
Gets page number by page. @param page the page.Class PdfDocument, PdfObject getPdfObject(int)@return page number.
Gets PdfObject by object number. @param objNum object number.Class PdfDocument, byte[] getXmpMetadata(boolean)@return PdfObject or {@code null}, if object not found.
Gets XMPMetadata or create a new one. @param createNew if true, create a new empty XMPMetadata if it did not present.Class PdfDocument, List@return existed or newly created XMPMetadata byte array.
Gets static copy of cross reference table. @returnClass PdfDocument, boolean movePage(PdfPage, int)a static copy of cross reference table
Moves page to new place in same document with all it tag structure @param page page to be moved in document if present @param insertBefore indicates before which page new one will be insertedClass PdfDocument, void movePage(int, int)toto @return true if this document contained the specified page
Moves page to new place in same document with all it tag structure @param pageNumber number of Page that will be moved @param insertBefore indicates before which page new one will be inserted toClass PdfDocument, void open(PdfVersion)
Initializes document. @param newPdfVersion new pdf version of the resultant file if stamper is used and the version needs toClass PdfDocument, boolean registerProduct(ProductData)bebe changed, or {@code null} otherwise
Registers a product for debugging purposes. @param productData product to be registered.Class PdfDocument, boolean removePage(PdfPage)@return true if the product hadn't been registered before.
Removes the first occurrence of the specified page from this document, if it is present. Returns true if this document contained the specified element (or equivalently, if this document changed as a result of the call). @param page page to be removed from this document, ifClass PdfDocument, void setXmpMetadata(XMPMeta, SerializeOptions)presentpresent @return true if this document contained the specified page
Sets the XMP Metadata. @param xmpMeta the xmpMetadata to set @param serializeOptions serialization options @throws XMPException on serialization errorsClass PdfDocument, void storeLinkAnnotation(PdfPage, PdfLinkAnnotation)
Save the link annotation in a temporary storage for further copying. Save destinations in a temporary storage for further copying. @param page just copied PdfPage link annotation belongs to. @param annotation PdfLinkAnnotation itself. @deprecated will be removed in next major version, it is being replaced with storeDestinationToReaddressClass PdfDocument, XMPMeta updateDefaultXmpMetadata()
Update XMP metadata values from PdfDocumentInfo. @return theXMPMetadataXMPMetadata @throws XMPException if the file is not well-formed XML or if parsing fails.
Checks if this PdfIndirectReference instance corresponds to free indirect reference. Indirect reference might be in a free state either because it was read as such from the opened existing PDF document or because it was set free via PdfIndirectReference.setFree() method.Class PdfIndirectReference, PdfObject setState(short)@return {@code true} if this PdfIndirectReference is free, {@code false} otherwise.
Sets special states of current object.@param state special flag of current object
Checks state of the flag of current object. @param state special flag toClass PdfObject, PdfObject clearState(short)checkcheck @return true if the state was set.
Clear state of the flag of current object. @param state special flag state toClass PdfObject, PdfObject copyTo(PdfDocument)clearclear @return this PdfObject
Copies object to a specified document.Class PdfObject, PdfObject copyTo(PdfDocument, boolean)
NOTE: Works only for objects that are read from document opened in reading mode, otherwise an exception is thrown. @param document document to copy object to.@return copied object.
Copies object to a specified document.Class PdfObject, PdfObject makeIndirect(PdfDocument)
NOTE: Works only for objects that are read from document opened in reading mode, otherwise an exception is thrown. @param document document to copy object to. @param allowDuplicating indicates if to allow copy objects which already have been copied. If object is associated with any indirect reference and allowDuplicatingisis false then already existing reference will be returned instead of copying object. If allowDuplicating is true then object will be copied and newindirectindirect reference will be assigned.@return copied object.
Marks object to be saved as indirect. @param document a document the indirect reference will belong to.Class PdfObject, PdfObject makeIndirect(PdfDocument, PdfIndirectReference)@return object itself.
Marks object to be saved as indirect. @param document a document the indirect reference will belong to. @param reference indirect reference which will be associated with thisClass PdfObject, PdfObject setModified()documentdocument @return object itself.
Sets the 'modified' flag to the indirect object, the flag denotes that the object was modifiedClass PdfObject, PdfObject setState(short)sincesince the document opening. It is recommended to set this flag after changing any PDF object.For example flag is used in the append mode (see StampingProperties.useAppendMode()). In append mode the whole document is preserved as is, and only changes to the document are appended to the end of the document file. Because of this, only modified objects need to be flushed and are allowed to be flushed (i.e. to be written). @return this PdfObject instance.
Sets special states of current object. @param state special flag of currentobjectobject @return this PdfObject
Create a PdfWriter writing to the passed File and with default writer properties. @param file File to write to.Class PdfWriter, constructor PdfWriter(String)@throws FileNotFoundException if the file exists but is a directory rather than a regular file, does not exist but cannot be created, or cannot be opened for any other reason
Create a PdfWriter writing to the passed filename and with default writer properties. @param filename filename of the resulting pdf.Class PdfWriter, constructor PdfWriter(String, WriterProperties)@throws FileNotFoundException if the file exists but is a directory rather than a regular file, does not exist but cannot be created, or cannot be opened for any other reason
Create a PdfWriter writing to the passed filename and using the passed writer properties. @param filename filename of the resulting pdf. @param properties writerproperties to use.Class PdfWriter, PdfWriter setCompressionLevel(int)@throws FileNotFoundException if the file exists but is a directory rather than a regular file, does not exist but cannot be created, or cannot be opened for any other reason
Sets default compression level for @see PdfStream. For more details @see com.itextpdf.io.source.DeflaterOutputStream. @param compressionLevel compression level.Class PdfWriter, PdfWriter setSmartMode(boolean)@return this PdfWriter instance
Sets the smart mode.
In smart mode when resources (such as fonts, images,...) are encountered, a reference to these resources is saved in a cache, so that they can be reused. This requires more memory, but reduces the file size of the resulting PDF document. @param smartMode True for enabling smart mode.@return this PdfWriter instance