Package com.itextpdf.html2pdf.attach
Class Attacher
java.lang.Object
com.itextpdf.html2pdf.attach.Attacher
Helper class to add parsed HTML content to an existing iText document, or to parse HTML to a list of iText elements.
-
Method Summary
Modifier and TypeMethodDescriptionstatic List
attach
(com.itextpdf.styledxmlparser.node.IDocumentNode documentNode, ConverterProperties converterProperties) Attaches the HTML content stored in a document node to a list ofIElement
objects.static com.itextpdf.layout.Document
attach
(com.itextpdf.styledxmlparser.node.IDocumentNode documentNode, com.itextpdf.kernel.pdf.PdfDocument pdfDocument, ConverterProperties converterProperties) Attaches the HTML content stored in a document node to an existing PDF document, using specific converter properties, and returning an iTextDocument
object.
-
Method Details
-
attach
public static com.itextpdf.layout.Document attach(com.itextpdf.styledxmlparser.node.IDocumentNode documentNode, com.itextpdf.kernel.pdf.PdfDocument pdfDocument, ConverterProperties converterProperties) Attaches the HTML content stored in a document node to an existing PDF document, using specific converter properties, and returning an iTextDocument
object.- Parameters:
-
documentNode
- the document node with the HTML -
pdfDocument
- thePdfDocument
instance -
converterProperties
- theConverterProperties
instance - Returns:
-
an iText
Document
object
-
attach
public static Listattach (com.itextpdf.styledxmlparser.node.IDocumentNode documentNode, ConverterProperties converterProperties) Attaches the HTML content stored in a document node to a list ofIElement
objects.- Parameters:
-
documentNode
- the document node with the HTML -
converterProperties
- theConverterProperties
instance - Returns:
-
the list of
IElement
objects
-