Module jpms_dss_pades_pdfbox
Class NativePdfBoxVisibleSignatureDrawer
java.lang.Object
eu.europa.esig.dss.pdf.pdfbox.visible.AbstractPdfBoxSignatureDrawer
eu.europa.esig.dss.pdf.pdfbox.visible.nativedrawer.NativePdfBoxVisibleSignatureDrawer
- All Implemented Interfaces:
PdfBoxSignatureDrawer,eu.europa.esig.dss.pdf.visible.SignatureDrawer,eu.europa.esig.dss.pdf.visible.SignatureFieldBoxBuilder
The native PDFBox signature drawer.
Creates text in the native way.
-
Field Summary
Fields inherited from class eu.europa.esig.dss.pdf.pdfbox.visible.AbstractPdfBoxSignatureDrawer
document, parameters, signatureOptions -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor instantiating object with default parameter values -
Method Summary
Modifier and TypeMethodDescriptionvoiddraw()protected eu.europa.esig.dss.pdf.visible.DSSFontMetricsGets the correspondingeu.europa.esig.dss.pdf.visible.DSSFontMetricsprotected StringReturns color space name for the provided imagevoidinit(eu.europa.esig.dss.pades.SignatureImageParameters parameters, org.apache.pdfbox.pdmodel.PDDocument document, org.apache.pdfbox.pdmodel.interactive.digitalsignature.SignatureOptions signatureOptions) Initializes the drawervoidsetResourcesHandlerBuilder(eu.europa.esig.dss.spi.signature.resources.DSSResourcesHandlerBuilder resourcesHandlerBuilder) SetsDSSResourcesFactoryBuilderto be used for aDSSResourcesFactorycreation Default :eu.europa.esig.dss.signature.resources.InMemoryResourcesHandler.Methods inherited from class eu.europa.esig.dss.pdf.pdfbox.visible.AbstractPdfBoxSignatureDrawer
addColorSpace, buildSignatureFieldBox, checkColorSpace, getPage, getPageAnnotationBox
-
Constructor Details
-
NativePdfBoxVisibleSignatureDrawer
public NativePdfBoxVisibleSignatureDrawer()Default constructor instantiating object with default parameter values
-
-
Method Details
-
setResourcesHandlerBuilder
public void setResourcesHandlerBuilder(eu.europa.esig.dss.spi.signature.resources.DSSResourcesHandlerBuilder resourcesHandlerBuilder) SetsDSSResourcesFactoryBuilderto be used for aDSSResourcesFactorycreation Default :eu.europa.esig.dss.signature.resources.InMemoryResourcesHandler. Works with data in memory.- Parameters:
resourcesHandlerBuilder-DSSResourcesHandlerBuilder
-
init
public void init(eu.europa.esig.dss.pades.SignatureImageParameters parameters, org.apache.pdfbox.pdmodel.PDDocument document, org.apache.pdfbox.pdmodel.interactive.digitalsignature.SignatureOptions signatureOptions) throws IOException Description copied from interface:PdfBoxSignatureDrawerInitializes the drawer- Specified by:
initin interfacePdfBoxSignatureDrawer- Overrides:
initin classAbstractPdfBoxSignatureDrawer- Parameters:
parameters-SignatureImageParametersdocument-PDDocumentsignatureOptions-SignatureOptions- Throws:
IOException- if an exception occurs
-
getDSSFontMetrics
protected eu.europa.esig.dss.pdf.visible.DSSFontMetrics getDSSFontMetrics()Description copied from class:AbstractPdfBoxSignatureDrawerGets the correspondingeu.europa.esig.dss.pdf.visible.DSSFontMetrics- Specified by:
getDSSFontMetricsin classAbstractPdfBoxSignatureDrawer- Returns:
DSSFontMetrics
-
draw
- Throws:
IOException
-
getExpectedColorSpaceName
Description copied from class:AbstractPdfBoxSignatureDrawerReturns color space name for the provided image- Specified by:
getExpectedColorSpaceNamein classAbstractPdfBoxSignatureDrawer- Returns:
Stringcolor space name- Throws:
IOException- in case of image reading error
-