Author: julien(a)jboss.com
Date: 2008-01-25 07:46:46 -0500 (Fri, 25 Jan 2008)
New Revision: 9604
Added:
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/SimpleMultiValuedPropertyMap.java
Removed:
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/MultiValuedPropertyMap.java
Modified:
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/Tools.java
modules/common/trunk/common/src/test/java/org/jboss/portal/test/common/util/MultiValuedPropertyMapTestCase.java
Log:
make MultiValuedMap an interface rather
Deleted:
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/MultiValuedPropertyMap.java
===================================================================
---
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/MultiValuedPropertyMap.java 2008-01-25
01:23:38 UTC (rev 9603)
+++
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/MultiValuedPropertyMap.java 2008-01-25
12:46:46 UTC (rev 9604)
@@ -1,230 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * This is free software; you can redistribute it and/or modify it *
- * under the terms of the GNU Lesser General Public License as *
- * published by the Free Software Foundation; either version 2.1 of *
- * the License, or (at your option) any later version. *
- * *
- * This software is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
- * Lesser General Public License for more details. *
- * *
- * You should have received a copy of the GNU Lesser General Public *
- * License along with this software; if not, write to the Free *
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org. *
- ******************************************************************************/
-package org.jboss.portal.common.util;
-
-import java.util.Map;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Set;
-import java.util.Collections;
-import java.util.LinkedList;
-
-/**
- * A map of multi valued properties
- *
- * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
- * @version $Revision: 630 $
- */
-public class MultiValuedPropertyMap<T>
-{
-
- /** . */
- private Map<String, LinkedList<T>> content;
-
- /**
- * @param name the property name
- * @param value the property value
- * @throws IllegalArgumentException if name or value is null
- */
- public void addProperty(String name, T value)
- {
- if (name == null)
- {
- throw new IllegalArgumentException("Name cannot be null");
- }
- if (value == null)
- {
- throw new IllegalArgumentException("Value cannot be null");
- }
- if (content == null)
- {
- content = new HashMap<String, LinkedList<T>>();
- }
-
- //
- LinkedList<T> values = content.get(name);
- if (values == null)
- {
- values = new LinkedList<T>();
- content.put(name, values);
- }
-
- //
- values.add(value);
- }
-
- /**
- * @param name the property name
- * @param value the property value
- * @throws IllegalArgumentException if name or value is null
- */
- public void setProperty(String name, T value)
- {
- if (name == null)
- {
- throw new IllegalArgumentException("Name cannot be null");
- }
- if (value == null)
- {
- throw new IllegalArgumentException("Value cannot be null");
- }
- if (content == null)
- {
- content = new HashMap<String, LinkedList<T>>();
- }
-
- //
- LinkedList<T> values = content.get(name);
- if (values == null)
- {
- values = new LinkedList<T>();
- content.put(name, values);
- }
- else
- {
- values.clear();
- }
-
- //
- values.add(value);
- }
-
- /**
- * Clear the properties.
- */
- public void clear()
- {
- if (content != null)
- {
- content.clear();
- }
- }
-
- /**
- * Returns the first property value or null if it cannot be found.
- *
- * @param name the property name
- * @return the property value
- * @throws IllegalArgumentException if the name argument is null
- */
- public T getPropertyValue(String name) throws IllegalArgumentException
- {
- if (name == null)
- {
- throw new IllegalArgumentException("Name cannot be null");
- }
- if (content == null)
- {
- return null;
- }
-
- //
- LinkedList<T> values = content.get(name);
- if (values == null)
- {
- return null;
- }
- else
- {
- return values.get(0);
- }
- }
-
- /**
- * Returns the list of values for a specified property.
- *
- * @param name the property name
- * @return the list of properties for the specified name or null if it does not exist
- * @throws IllegalArgumentException if name argument is null
- */
- public List<T> getPropertyValues(String name)
- {
- if (name == null)
- {
- throw new IllegalArgumentException("Name cannot be null");
- }
- if (content == null)
- {
- return null;
- }
- return content.get(name);
- }
-
- /**
- * Returns the set of property names.
- *
- * @return the set of property names
- */
- public Set<String> getPropertyNames()
- {
- if (content == null)
- {
- return Collections.emptySet();
- }
- return content.keySet();
- }
-
- /**
- * Append the multi valued property map to this one. Entries from the provided map
that do not exist
- * in the current map are created, entries that exist in both maps are concatenated in
the existing map
- * with the values of the existing map being before the values of the provided map.
- *
- * @param appended the property map to append
- * @throws IllegalArgumentException if the provided map is null
- */
- public void append(MultiValuedPropertyMap<T> appended) throws
IllegalArgumentException
- {
- if (appended == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- if (appended.content != null)
- {
- for (Map.Entry<String, LinkedList<T>> entry :
appended.content.entrySet())
- {
- String name = entry.getKey();
-
- //
- if (content == null)
- {
- content = new HashMap<String,
LinkedList<T>>(appended.content.size());
- }
-
- //
- LinkedList<T> values = content.get(name);
-
- //
- if (values != null)
- {
- values.addAll(entry.getValue());
- }
- else
- {
- content.put(name, new LinkedList<T>(entry.getValue()));
- }
- }
- }
- }
-}
Copied:
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/SimpleMultiValuedPropertyMap.java
(from rev 9599,
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/MultiValuedPropertyMap.java)
===================================================================
---
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/SimpleMultiValuedPropertyMap.java
(rev 0)
+++
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/SimpleMultiValuedPropertyMap.java 2008-01-25
12:46:46 UTC (rev 9604)
@@ -0,0 +1,268 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.common.util;
+
+import java.util.Map;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Set;
+import java.util.Collections;
+import java.util.LinkedList;
+
+/**
+ * A map of multi valued properties.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class SimpleMultiValuedPropertyMap<T> implements
MultiValuedPropertyMap<T>
+{
+
+ /** . */
+ private Map<String, LinkedList<T>> content;
+
+ /**
+ * @param key the property key
+ * @param value the property value
+ * @throws IllegalArgumentException if name or value is null
+ */
+ public void addValue(String key, T value)
+ {
+ if (key == null)
+ {
+ throw new IllegalArgumentException("Name cannot be null");
+ }
+ if (value == null)
+ {
+ throw new IllegalArgumentException("Value cannot be null");
+ }
+ if (content == null)
+ {
+ content = new HashMap<String, LinkedList<T>>();
+ }
+
+ //
+ LinkedList<T> values = content.get(key);
+ if (values == null)
+ {
+ values = new LinkedList<T>();
+ content.put(key, values);
+ }
+
+ //
+ values.add(value);
+ }
+
+ /**
+ * @param key the property key
+ * @param value the property value
+ * @throws IllegalArgumentException if name or value is null
+ */
+ public void setValue(String key, T value)
+ {
+ if (key == null)
+ {
+ throw new IllegalArgumentException("Name cannot be null");
+ }
+ if (value == null)
+ {
+ throw new IllegalArgumentException("Value cannot be null");
+ }
+ if (content == null)
+ {
+ content = new HashMap<String, LinkedList<T>>();
+ }
+
+ //
+ LinkedList<T> values = content.get(key);
+ if (values == null)
+ {
+ values = new LinkedList<T>();
+ content.put(key, values);
+ }
+ else
+ {
+ values.clear();
+ }
+
+ //
+ values.add(value);
+ }
+
+ /**
+ * Clear the properties.
+ */
+ public void clear()
+ {
+ if (content != null)
+ {
+ content.clear();
+ }
+ }
+
+ /**
+ * Returns the first property value or null if it cannot be found.
+ *
+ * @param key the property key
+ * @return the property value
+ * @throws IllegalArgumentException if the name argument is null
+ */
+ public T getValue(String key) throws IllegalArgumentException
+ {
+ if (key == null)
+ {
+ throw new IllegalArgumentException("Name cannot be null");
+ }
+ if (content == null)
+ {
+ return null;
+ }
+
+ //
+ LinkedList<T> values = content.get(key);
+ if (values == null)
+ {
+ return null;
+ }
+ else
+ {
+ return values.get(0);
+ }
+ }
+
+ /**
+ * Returns the list of values for a specified property.
+ *
+ * @param key the property key
+ * @return the list of properties for the specified name or null if it does not exist
+ * @throws IllegalArgumentException if name argument is null
+ */
+ public List<T> getValues(String key)
+ {
+ if (key == null)
+ {
+ throw new IllegalArgumentException("Name cannot be null");
+ }
+ if (content == null)
+ {
+ return null;
+ }
+ return content.get(key);
+ }
+
+ /**
+ * Returns the set of property keys.
+ *
+ * @return the set of property keys
+ */
+ public Set<String> keySet()
+ {
+ if (content == null)
+ {
+ return Collections.emptySet();
+ }
+ return content.keySet();
+ }
+
+ public int size()
+ {
+ if (content == null)
+ {
+ return 0;
+ }
+ return content.size();
+ }
+
+ /**
+ * Append the multi valued property map to this one. Entries from the provided map
that do not exist
+ * in the current map are created, entries that exist in both maps are concatenated in
the existing map
+ * with the values of the existing map being before the values of the provided map.
+ *
+ * @param appended the property map to append
+ * @throws IllegalArgumentException if the provided map is null
+ */
+ public void append(MultiValuedPropertyMap<T> appended) throws
IllegalArgumentException
+ {
+ if (appended == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ if (appended instanceof SimpleMultiValuedPropertyMap)
+ {
+ Map<String, LinkedList<T>> appendedContent =
((SimpleMultiValuedPropertyMap<T>)appended).content;
+
+ //
+ if (appendedContent != null)
+ {
+ for (Map.Entry<String, LinkedList<T>> entry :
appendedContent.entrySet())
+ {
+ String name = entry.getKey();
+
+ //
+ if (content == null)
+ {
+ content = new HashMap<String,
LinkedList<T>>(appendedContent.size());
+ }
+
+ //
+ LinkedList<T> values = content.get(name);
+
+ //
+ if (values != null)
+ {
+ values.addAll(entry.getValue());
+ }
+ else
+ {
+ content.put(name, new LinkedList<T>(entry.getValue()));
+ }
+ }
+ }
+ }
+ else
+ {
+ for (String key : appended.keySet())
+ {
+ List<T> values = appended.getValues(key);
+
+ //
+ if (content == null)
+ {
+ content = new HashMap<String,
LinkedList<T>>(appended.size());
+ }
+
+ //
+ if (values != null)
+ {
+ values.addAll(values);
+ }
+ else
+ {
+ content.put(key, new LinkedList<T>(values));
+ }
+ }
+ }
+ }
+}
Modified:
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/Tools.java
===================================================================
---
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/Tools.java 2008-01-25
01:23:38 UTC (rev 9603)
+++
modules/common/trunk/common/src/main/java/org/jboss/portal/common/util/Tools.java 2008-01-25
12:46:46 UTC (rev 9604)
@@ -46,6 +46,7 @@
import java.util.NoSuchElementException;
import java.util.ResourceBundle;
import java.util.Set;
+import java.util.Collections;
/**
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
@@ -965,4 +966,59 @@
}
}
}
+
+ public static <T> MultiValuedPropertyMap<T> emptyMultiValuedPropertyMap()
+ {
+ return new MultiValuedPropertyMap<T>()
+ {
+ public T getValue(String key) throws IllegalArgumentException
+ {
+ if (key == null)
+ {
+ throw new IllegalArgumentException("Key cannot be null");
+ }
+ return null;
+ }
+
+ public List<T> getValues(String key) throws IllegalArgumentException
+ {
+ if (key == null)
+ {
+ throw new IllegalArgumentException("Key cannot be null");
+ }
+ return null;
+ }
+
+ public void addValue(String key, T value) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public void setValue(String key, T value) throws IllegalArgumentException
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public Set<String> keySet()
+ {
+ return Collections.emptySet();
+ }
+
+ public int size()
+ {
+ return 0;
+ }
+
+ public void clear()
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public void append(MultiValuedPropertyMap<T> appended) throws
IllegalArgumentException
+ {
+ throw new UnsupportedOperationException();
+ }
+ };
+ }
+
}
\ No newline at end of file
Modified:
modules/common/trunk/common/src/test/java/org/jboss/portal/test/common/util/MultiValuedPropertyMapTestCase.java
===================================================================
---
modules/common/trunk/common/src/test/java/org/jboss/portal/test/common/util/MultiValuedPropertyMapTestCase.java 2008-01-25
01:23:38 UTC (rev 9603)
+++
modules/common/trunk/common/src/test/java/org/jboss/portal/test/common/util/MultiValuedPropertyMapTestCase.java 2008-01-25
12:46:46 UTC (rev 9604)
@@ -23,7 +23,7 @@
package org.jboss.portal.test.common.util;
import junit.framework.TestCase;
-import org.jboss.portal.common.util.MultiValuedPropertyMap;
+import org.jboss.portal.common.util.SimpleMultiValuedPropertyMap;
import org.jboss.portal.common.util.Tools;
/**
@@ -44,56 +44,56 @@
public void testA()
{
- MultiValuedPropertyMap<String> props = new
MultiValuedPropertyMap<String>();
+ SimpleMultiValuedPropertyMap<String> props = new
SimpleMultiValuedPropertyMap<String>();
- props.setProperty("name1", "value1");
+ props.setValue("name1", "value1");
- props.addProperty("name2", "value2");
+ props.addValue("name2", "value2");
- props.setProperty("name3", "value3-1");
- props.addProperty("name3", "value3-2");
+ props.setValue("name3", "value3-1");
+ props.addValue("name3", "value3-2");
- props.addProperty("name4", "value4-1");
- props.addProperty("name4", "value4-2");
+ props.addValue("name4", "value4-1");
+ props.addValue("name4", "value4-2");
- props.setProperty("name5", "value5-1");
- props.setProperty("name5", "value5-2");
+ props.setValue("name5", "value5-1");
+ props.setValue("name5", "value5-2");
- props.addProperty("name6", "value6-1");
- props.setProperty("name6", "value6-2");
+ props.addValue("name6", "value6-1");
+ props.setValue("name6", "value6-2");
- assertEquals("value1", props.getPropertyValue("name1"));
- assertEquals(1, props.getPropertyValues("name1").size());
- assertEquals("value1",
props.getPropertyValues("name1").get(0));
+ assertEquals("value1", props.getValue("name1"));
+ assertEquals(1, props.getValues("name1").size());
+ assertEquals("value1", props.getValues("name1").get(0));
- assertEquals("value2", props.getPropertyValue("name2"));
- assertEquals(1, props.getPropertyValues("name2").size());
- assertEquals("value2",
props.getPropertyValues("name2").get(0));
+ assertEquals("value2", props.getValue("name2"));
+ assertEquals(1, props.getValues("name2").size());
+ assertEquals("value2", props.getValues("name2").get(0));
- assertEquals("value3-1", props.getPropertyValue("name3"));
- assertEquals(2, props.getPropertyValues("name3").size());
- assertEquals("value3-1",
props.getPropertyValues("name3").get(0));
- assertEquals("value3-2",
props.getPropertyValues("name3").get(1));
+ assertEquals("value3-1", props.getValue("name3"));
+ assertEquals(2, props.getValues("name3").size());
+ assertEquals("value3-1", props.getValues("name3").get(0));
+ assertEquals("value3-2", props.getValues("name3").get(1));
- assertEquals("value4-1", props.getPropertyValue("name4"));
- assertEquals(2, props.getPropertyValues("name4").size());
- assertEquals("value4-1",
props.getPropertyValues("name4").get(0));
- assertEquals("value4-2",
props.getPropertyValues("name4").get(1));
+ assertEquals("value4-1", props.getValue("name4"));
+ assertEquals(2, props.getValues("name4").size());
+ assertEquals("value4-1", props.getValues("name4").get(0));
+ assertEquals("value4-2", props.getValues("name4").get(1));
- assertEquals(1, props.getPropertyValues("name5").size());
- assertEquals("value5-2",
props.getPropertyValues("name5").get(0));
+ assertEquals(1, props.getValues("name5").size());
+ assertEquals("value5-2", props.getValues("name5").get(0));
- assertEquals("value6-2", props.getPropertyValue("name6"));
- assertEquals(1, props.getPropertyValues("name6").size());
- assertEquals("value6-2",
props.getPropertyValues("name6").get(0));
+ assertEquals("value6-2", props.getValue("name6"));
+ assertEquals(1, props.getValues("name6").size());
+ assertEquals("value6-2", props.getValues("name6").get(0));
- assertEquals(null, props.getPropertyValues("not here"));
- assertNull(props.getPropertyValue("not here"));
- assertEquals(Tools.toSet("name1", "name2", "name3",
"name4", "name5", "name6"), props.getPropertyNames());
+ assertEquals(null, props.getValues("not here"));
+ assertNull(props.getValue("not here"));
+ assertEquals(Tools.toSet("name1", "name2", "name3",
"name4", "name5", "name6"), props.keySet());
try
{
- props.setProperty(null, "not null");
+ props.setValue(null, "not null");
fail("Expected IllegalArgumentException");
}
catch (IllegalArgumentException e)
@@ -102,7 +102,7 @@
try
{
- props.setProperty("not null", null);
+ props.setValue("not null", null);
fail("Expected IllegalArgumentException");
}
catch (IllegalArgumentException e)
@@ -111,7 +111,7 @@
try
{
- props.setProperty(null, null);
+ props.setValue(null, null);
fail("Expected IllegalArgumentException");
}
catch (IllegalArgumentException e)
@@ -121,61 +121,61 @@
public void testAppend1()
{
- MultiValuedPropertyMap<String> props = new
MultiValuedPropertyMap<String>();
- MultiValuedPropertyMap<String> appended = new
MultiValuedPropertyMap<String>();
- appended.setProperty("foo", "bar");
+ SimpleMultiValuedPropertyMap<String> props = new
SimpleMultiValuedPropertyMap<String>();
+ SimpleMultiValuedPropertyMap<String> appended = new
SimpleMultiValuedPropertyMap<String>();
+ appended.setValue("foo", "bar");
props.append(appended);
//
- assertEquals(Tools.toSet("foo"), props.getPropertyNames());
- assertEquals(Tools.toList("bar"),
props.getPropertyValues("foo"));
+ assertEquals(Tools.toSet("foo"), props.keySet());
+ assertEquals(Tools.toList("bar"), props.getValues("foo"));
}
public void testAppend2()
{
- MultiValuedPropertyMap<String> props = new
MultiValuedPropertyMap<String>();
- props.setProperty("foo", "bar");
+ SimpleMultiValuedPropertyMap<String> props = new
SimpleMultiValuedPropertyMap<String>();
+ props.setValue("foo", "bar");
//
- MultiValuedPropertyMap<String> appended = new
MultiValuedPropertyMap<String>();
+ SimpleMultiValuedPropertyMap<String> appended = new
SimpleMultiValuedPropertyMap<String>();
props.append(appended);
//
- assertEquals(Tools.toSet("foo"), props.getPropertyNames());
- assertEquals(Tools.toList("bar"),
props.getPropertyValues("foo"));
+ assertEquals(Tools.toSet("foo"), props.keySet());
+ assertEquals(Tools.toList("bar"), props.getValues("foo"));
}
public void testAppend3()
{
- MultiValuedPropertyMap<String> props = new
MultiValuedPropertyMap<String>();
- props.setProperty("foo", "foo1");
- props.setProperty("bar", "bar1");
- props.addProperty("bar", "bar2");
- props.setProperty("juu", "juu1");
- props.setProperty("daa", "daa1");
- props.addProperty("daa", "daa2");
+ SimpleMultiValuedPropertyMap<String> props = new
SimpleMultiValuedPropertyMap<String>();
+ props.setValue("foo", "foo1");
+ props.setValue("bar", "bar1");
+ props.addValue("bar", "bar2");
+ props.setValue("juu", "juu1");
+ props.setValue("daa", "daa1");
+ props.addValue("daa", "daa2");
//
- MultiValuedPropertyMap<String> appended = new
MultiValuedPropertyMap<String>();
- appended.setProperty("juu", "juu2");
- appended.addProperty("juu", "juu3");
- appended.setProperty("daa", "daa3");
- appended.setProperty("zoo", "zoo1");
- appended.setProperty("tee", "tee1");
- appended.addProperty("tee", "tee2");
+ SimpleMultiValuedPropertyMap<String> appended = new
SimpleMultiValuedPropertyMap<String>();
+ appended.setValue("juu", "juu2");
+ appended.addValue("juu", "juu3");
+ appended.setValue("daa", "daa3");
+ appended.setValue("zoo", "zoo1");
+ appended.setValue("tee", "tee1");
+ appended.addValue("tee", "tee2");
//
props.append(appended);
//
-
assertEquals(Tools.toSet("foo","bar","juu","daa","zoo","tee"),
props.getPropertyNames());
- assertEquals(Tools.toList("foo1"),
props.getPropertyValues("foo"));
- assertEquals(Tools.toList("bar1", "bar2"),
props.getPropertyValues("bar"));
- assertEquals(Tools.toList("juu1", "juu2","juu3"),
props.getPropertyValues("juu"));
- assertEquals(Tools.toList("daa1", "daa2","daa3"),
props.getPropertyValues("daa"));
- assertEquals(Tools.toList("zoo1"),
props.getPropertyValues("zoo"));
- assertEquals(Tools.toList("tee1","tee2"),
props.getPropertyValues("tee"));
+
assertEquals(Tools.toSet("foo","bar","juu","daa","zoo","tee"),
props.keySet());
+ assertEquals(Tools.toList("foo1"), props.getValues("foo"));
+ assertEquals(Tools.toList("bar1", "bar2"),
props.getValues("bar"));
+ assertEquals(Tools.toList("juu1", "juu2","juu3"),
props.getValues("juu"));
+ assertEquals(Tools.toList("daa1", "daa2","daa3"),
props.getValues("daa"));
+ assertEquals(Tools.toList("zoo1"), props.getValues("zoo"));
+ assertEquals(Tools.toList("tee1","tee2"),
props.getValues("tee"));
}
}