brooklyn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From henev...@apache.org
Subject [12/13] brooklyn-server git commit: Add MapConfigKey.toString
Date Tue, 29 Nov 2016 13:40:26 GMT
Add MapConfigKey.toString

Project: http://git-wip-us.apache.org/repos/asf/brooklyn-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-server/commit/131d356c
Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-server/tree/131d356c
Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-server/diff/131d356c

Branch: refs/heads/master
Commit: 131d356c5e3e167aaabd48cffbf0e5a8370be88d
Parents: a9ec838
Author: Aled Sage <aled.sage@gmail.com>
Authored: Thu Nov 17 14:48:41 2016 +0000
Committer: Aled Sage <aled.sage@gmail.com>
Committed: Mon Nov 28 21:11:48 2016 +0000

----------------------------------------------------------------------
 .../java/org/apache/brooklyn/core/config/ListConfigKey.java     | 5 +++++
 .../main/java/org/apache/brooklyn/core/config/MapConfigKey.java | 5 +++++
 .../main/java/org/apache/brooklyn/core/config/SetConfigKey.java | 5 +++++
 3 files changed, 15 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/131d356c/core/src/main/java/org/apache/brooklyn/core/config/ListConfigKey.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/config/ListConfigKey.java b/core/src/main/java/org/apache/brooklyn/core/config/ListConfigKey.java
index 06a29bd..816af99 100644
--- a/core/src/main/java/org/apache/brooklyn/core/config/ListConfigKey.java
+++ b/core/src/main/java/org/apache/brooklyn/core/config/ListConfigKey.java
@@ -73,6 +73,11 @@ public class ListConfigKey<V> extends AbstractCollectionConfigKey<List<?
extends
     }
 
     @Override
+    public String toString() {
+        return String.format("%s[ListConfigKey:%s]", name, getTypeName());
+    }
+
+    @Override
     protected List<Object> merge(boolean unmodifiable, Iterable<?>... sets) {
         MutableList<Object> result = MutableList.of();
         for (Iterable<?> set: sets) result.addAll(set);

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/131d356c/core/src/main/java/org/apache/brooklyn/core/config/MapConfigKey.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/config/MapConfigKey.java b/core/src/main/java/org/apache/brooklyn/core/config/MapConfigKey.java
index a0b9bd7..367259d 100644
--- a/core/src/main/java/org/apache/brooklyn/core/config/MapConfigKey.java
+++ b/core/src/main/java/org/apache/brooklyn/core/config/MapConfigKey.java
@@ -147,6 +147,11 @@ public class MapConfigKey<V> extends AbstractStructuredConfigKey<Map<String,V>,M
         super((Class)Map.class, subType, name, description, defaultValue);
     }
 
+    @Override
+    public String toString() {
+        return String.format("%s[MapConfigKey:%s]", name, getTypeName());
+    }
+
     public ConfigKey<V> subKey(String subName) {
         return super.subKey(subName);
     }

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/131d356c/core/src/main/java/org/apache/brooklyn/core/config/SetConfigKey.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/config/SetConfigKey.java b/core/src/main/java/org/apache/brooklyn/core/config/SetConfigKey.java
index f199c38..55c9a05 100644
--- a/core/src/main/java/org/apache/brooklyn/core/config/SetConfigKey.java
+++ b/core/src/main/java/org/apache/brooklyn/core/config/SetConfigKey.java
@@ -64,6 +64,11 @@ public class SetConfigKey<V> extends AbstractCollectionConfigKey<Set<?
extends V
     }
 
     @Override
+    public String toString() {
+        return String.format("%s[SetConfigKey:%s]", name, getTypeName());
+    }
+
+    @Override
     protected Set<Object> merge(boolean unmodifiable, Iterable<?>... sets) {
         MutableSet<Object> result = MutableSet.of();
         for (Iterable<?> set: sets) result.addAll(set);


Mime
View raw message