Package com.itextpdf.text.pdf
Class XmlSignatureAppearance
java.lang.Object
com.itextpdf.text.pdf.XmlSignatureAppearance
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate String
Holds value of property xades:Description.private String
Holds value of property xades:MimeType.private Certificate
private Calendar
Holds value of property xades:SigningTime.private PdfStamper
private PdfStamperImp
private XmlLocator
private XpathConstructor
-
Constructor Summary
ConstructorsConstructorDescriptionXmlSignatureAppearance
(PdfStamperImp writer) Constructs XmlSignatureAppearance object. -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Close PdfStamperGets the signature date.Helps to locate xml streamConstructor for xpath expression in case signing only part of XML document.void
setCertificate
(Certificate signCertificate) Sets the certificate used to provide the text in the appearance.void
setDescription
(String description) void
setMimeType
(String mimeType) void
setSignDate
(Calendar signDate) Sets the signature date.void
setStamper
(PdfStamper stamper) void
setXmlLocator
(XmlLocator xmlLocator) void
setXpathConstructor
(XpathConstructor xpathConstructor)
-
Field Details
-
writer
-
stamper
-
signCertificate
-
xmlLocator
-
xpathConstructor
-
signDate
Holds value of property xades:SigningTime. -
description
Holds value of property xades:Description. -
mimeType
Holds value of property xades:MimeType.
-
-
Constructor Details
-
XmlSignatureAppearance
XmlSignatureAppearance(PdfStamperImp writer) Constructs XmlSignatureAppearance object.- Parameters:
writer
- the writer to which the signature will be written.
-
-
Method Details
-
getWriter
-
getStamper
-
setStamper
-
setCertificate
Sets the certificate used to provide the text in the appearance. This certificate doesn't take part in the actual signing process.- Parameters:
signCertificate
- the certificate
-
getCertificate
-
setDescription
-
getDescription
-
getMimeType
-
setMimeType
-
getSignDate
Gets the signature date.- Returns:
- the signature date
-
setSignDate
Sets the signature date.- Parameters:
signDate
- the signature date
-
getXmlLocator
Helps to locate xml stream- Returns:
- XmlLocator, cannot be null.
-
setXmlLocator
-
getXpathConstructor
Constructor for xpath expression in case signing only part of XML document.- Returns:
- XpathConstructor, can be null
-
setXpathConstructor
-
close
Close PdfStamper- Throws:
IOException
DocumentException
-