public class SignatureField extends NativeObject
The existence of signature fields does not necessarily mean that the
document is signed. This depends on the property getIsSigned()
.
All properties are taken from information in the PDF, not from the actual digital signature. For some properties, those values are redundant and the value from the actual digital signature should take precedence.
The existence of a signed signature field does not imply, that the signature is valid, the signature is actually not validated at all.
Modifier and Type | Method and Description |
---|---|
static SignatureField |
createDynamicObject(long handle) |
java.lang.String |
getContactInfo()
The contact information of the signer (Getter)
|
java.time.OffsetDateTime |
getDate()
The date and time of signing (Getter)
|
boolean |
getIsSigned()
Whether the field is signed (Getter)
|
boolean |
getIsVisible()
The visibility of the signature field (Getter)
|
java.lang.String |
getLocation()
The location of signing (Getter)
|
java.lang.String |
getName()
The name of the person or authority signing the document.
|
java.lang.String |
getReason()
The reason for the signing (Getter)
|
equals, hashCode
public static SignatureField createDynamicObject(long handle)
public boolean getIsSigned()
true
the signature field contains an actual digital signature.
false
the signature field is a placeholder that is yet to be signed.
All properties except getIsVisible()
can be ignored.
java.lang.IllegalStateException
- if the object has already been closedpublic boolean getIsVisible()
true
, the signature field has a visual appearance on the page.java.lang.IllegalStateException
- if the object has already been closedpublic java.lang.String getName()
This property represents the name as stored in the PDF.
Note: This property should be used with care, as the value can differ from the name as stored in the signer certificate. If that's the case, the name in the signer certificate should be used.
java.lang.IllegalStateException
- if the object has already been closedpublic java.lang.String getLocation()
java.lang.IllegalStateException
- if the object has already been closedpublic java.lang.String getReason()
java.lang.IllegalStateException
- if the object has already been closedpublic java.lang.String getContactInfo()
java.lang.IllegalStateException
- if the object has already been closedpublic java.time.OffsetDateTime getDate() throws CorruptException
Depending on the signature handler, this may be a normal unverified computer time or a time generated in a verifiable way from a secure time server.
Note: This property should be used with care, as the value can differ from the date as stored in the cryptographic signature itself. If that's the case, the name in the signer certificate should be used.
java.lang.IllegalStateException
- if the object has already been closedCorruptException
- The date is corrupt.