summaryrefslogtreecommitdiff
path: root/eaaf_core_api
diff options
context:
space:
mode:
authorThomas Lenz <thomas.lenz@egiz.gv.at>2019-08-08 14:58:05 +0200
committerThomas Lenz <thomas.lenz@egiz.gv.at>2019-08-08 14:58:05 +0200
commitbe87f006afb8f224afe57950d1b72cb4117a5835 (patch)
treef2f8d80d74d7078c1d689c4772e50d8851828264 /eaaf_core_api
parenta602137e7ab86d7fe59edde9e2ee40210ac2a247 (diff)
downloadEAAF-Components-be87f006afb8f224afe57950d1b72cb4117a5835.tar.gz
EAAF-Components-be87f006afb8f224afe57950d1b72cb4117a5835.tar.bz2
EAAF-Components-be87f006afb8f224afe57950d1b72cb4117a5835.zip
Refactor GUIBuilderConfiguration to support Map and List based property format
Diffstat (limited to 'eaaf_core_api')
-rw-r--r--eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/GroupDefinition.java34
-rw-r--r--eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/ModifyableGuiBuilderConfiguration.java4
2 files changed, 36 insertions, 2 deletions
diff --git a/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/GroupDefinition.java b/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/GroupDefinition.java
new file mode 100644
index 00000000..441f1917
--- /dev/null
+++ b/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/GroupDefinition.java
@@ -0,0 +1,34 @@
+package at.gv.egiz.eaaf.core.api.gui;
+
+public class GroupDefinition {
+
+ private final String name;
+ private final TYPE type;
+
+ private GroupDefinition(String name, TYPE type) {
+ this.name = name;
+ this.type = type;
+ }
+
+ public static GroupDefinition getInstance(String name, TYPE type) {
+ return new GroupDefinition(name, type);
+ }
+
+ public String getName() {
+ return name;
+ }
+
+ public TYPE getType() {
+ return type;
+ }
+
+ public enum TYPE {
+ LIST("list"),
+ MAP("map");
+
+ private TYPE(String type) {
+ }
+ }
+
+}
+
diff --git a/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/ModifyableGuiBuilderConfiguration.java b/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/ModifyableGuiBuilderConfiguration.java
index 19fe9a12..6df6a78f 100644
--- a/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/ModifyableGuiBuilderConfiguration.java
+++ b/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/gui/ModifyableGuiBuilderConfiguration.java
@@ -39,7 +39,7 @@ public interface ModifyableGuiBuilderConfiguration {
* @param key velocity context key
* @param value of this key
*/
- void putCustomParameterWithOutEscaption(@Nullable String group, @Nonnull String key, @Nonnull Object value);
+ void putCustomParameterWithOutEscaption(@Nullable GroupDefinition group, @Nonnull String key, @Nonnull Object value);
/**
* Add a key/value pair into Velocity context.<br>
@@ -49,6 +49,6 @@ public interface ModifyableGuiBuilderConfiguration {
* @param key velocity context key
* @param value of this key
*/
- void putCustomParameter(@Nullable String group, @Nonnull String key, @Nonnull String value);
+ void putCustomParameter(@Nullable GroupDefinition group, @Nonnull String key, @Nonnull String value);
} \ No newline at end of file