diff options
author | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-10-20 11:58:13 +0200 |
---|---|---|
committer | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-10-20 11:58:13 +0200 |
commit | 217ffc112176ded156ef581c73409d8fa194bb54 (patch) | |
tree | 6e138e9a04216240a2fbc8dd06d75022225053b2 /pdf-as-lib | |
parent | a19cbbe8105efe64c3a57823e087fa8228e7136d (diff) | |
download | pdf-as-4-217ffc112176ded156ef581c73409d8fa194bb54.tar.gz pdf-as-4-217ffc112176ded156ef581c73409d8fa194bb54.tar.bz2 pdf-as-4-217ffc112176ded156ef581c73409d8fa194bb54.zip |
Is Visible configuration added
Diffstat (limited to 'pdf-as-lib')
2 files changed, 15 insertions, 1 deletions
diff --git a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/api/IConfigurationConstants.java b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/api/IConfigurationConstants.java index a3988add..03e72ecc 100644 --- a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/api/IConfigurationConstants.java +++ b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/api/IConfigurationConstants.java @@ -35,6 +35,7 @@ public interface IConfigurationConstants { public static final String TYPE = "type"; public static final String TABLE = "table"; public static final String MAIN = "main"; + public static final String ISVISIBLE = "isvisible"; public static final String POS = "pos"; public static final String DEFAULT = "default"; public static final String SEPERATOR = "."; diff --git a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/configuration/SignatureProfileConfiguration.java b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/configuration/SignatureProfileConfiguration.java index a7dd3138..04448b96 100644 --- a/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/configuration/SignatureProfileConfiguration.java +++ b/pdf-as-lib/src/main/java/at/gv/egiz/pdfas/lib/impl/configuration/SignatureProfileConfiguration.java @@ -39,7 +39,20 @@ public class SignatureProfileConfiguration extends SpecificBaseConfiguration public boolean isVisualSignature() { String key = SIG_OBJECT + SEPERATOR + profileID + SEPERATOR + TABLE + SEPERATOR + MAIN; - return this.configuration.hasPrefix(key); + + String isVisibleKey = SIG_OBJECT + SEPERATOR + profileID + SEPERATOR + ISVISIBLE; + + String isVisibleValue = this.configuration.getValue(isVisibleKey); + + boolean isVisible = true; + + if(isVisibleValue != null) { + if(isVisibleValue.equals(FALSE)) { + isVisible = false; + } + } + + return this.configuration.hasPrefix(key) && isVisible; } public String getDefaultPositioning() { |