Class SignatureOptions
java.lang.Object
org.apache.pdfbox.pdmodel.interactive.digitalsignature.SignatureOptions
This contains the visual signature as a COSDocument, its preferred size and the page.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes the visual signature COSDocument, if any.intgetPage()Get the 1-based page number.intGet the preferred size of the signature.Get the visual signature.voidsetPage(int pageNo) Set the 1-based page number.voidsetPreferedSignatureSize(int size) Set the preferred size of the signature.voidReads the visual signature from the given input stream.voidsetVisualSignature(PDVisibleSigProperties visSignatureProperties) Reads the visual signature from the given visual signature properties
-
Constructor Details
-
SignatureOptions
public SignatureOptions()
-
-
Method Details
-
setPage
public void setPage(int pageNo) Set the 1-based page number.- Parameters:
pageNo- the page number
-
getPage
public int getPage()Get the 1-based page number.- Returns:
- the page number
-
setVisualSignature
Reads the visual signature from the given input stream.- Parameters:
is- the input stream containing the visual signature- Throws:
IOException- when something went wrong during parsing
-
setVisualSignature
Reads the visual signature from the given visual signature properties- Parameters:
visSignatureProperties- thePDVisibleSigPropertiesobject containing the visual signature- Throws:
IOException- when something went wrong during parsing- Since:
- 1.8.3
-
getVisualSignature
Get the visual signature.- Returns:
- the visual signature
-
getPreferedSignatureSize
public int getPreferedSignatureSize()Get the preferred size of the signature.- Returns:
- the preferred size
-
setPreferedSignatureSize
public void setPreferedSignatureSize(int size) Set the preferred size of the signature.- Parameters:
size- the size of the signature
-
close
Closes the visual signature COSDocument, if any.- Throws:
IOException- if the document could not be closed
-