From 1a46583236b58a77b11abc91681f697c4cb7e46e Mon Sep 17 00:00:00 2001
From: Thomas <>
Date: Tue, 27 Jun 2023 07:05:11 +0200
Subject: chore(core): add methods to get boolean configuration-values into
configuration class
---
.../java/at/gv/egiz/pdfas/common/settings/ISettings.java | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
(limited to 'pdf-as-common/src/main/java/at/gv/egiz')
diff --git a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/common/settings/ISettings.java b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/common/settings/ISettings.java
index 42cdb8ab..43139966 100644
--- a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/common/settings/ISettings.java
+++ b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/common/settings/ISettings.java
@@ -29,6 +29,22 @@ import java.util.Vector;
public interface ISettings {
public String getValue(String key);
public boolean hasValue(String key);
+
+ /**
+ * Get boolean configuration value.
+ * @param key Configuration key
+ * @return true
if configuration exists and has value true
, otherwise false
+ */
+ public boolean isValue(String key);
+
+ /**
+ * Get boolean configuration value.
+ * @param key Configuration key
+ * @param defaultValue Value if configuration does not exist
+ * @return true
if configuration exists and has value true
, otherwise default value
+ */
+ public boolean isValue(String key, boolean defaultValue);
+
public boolean hasPrefix(String prefix);
public Map getValuesPrefix(String prefix);
public Vector getFirstLevelKeys(String prefix);
--
cgit v1.2.3