Author: chris.laprun(a)jboss.com
Date: 2010-03-01 07:37:35 -0500 (Mon, 01 Mar 2010)
New Revision: 1913
Modified:
portal/trunk/component/portal/src/main/java/org/exoplatform/portal/pom/config/Utils.java
portal/trunk/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/mapping/MappedMap.java
Log:
- Minor.
Modified:
portal/trunk/component/portal/src/main/java/org/exoplatform/portal/pom/config/Utils.java
===================================================================
---
portal/trunk/component/portal/src/main/java/org/exoplatform/portal/pom/config/Utils.java 2010-03-01
12:31:01 UTC (rev 1912)
+++
portal/trunk/component/portal/src/main/java/org/exoplatform/portal/pom/config/Utils.java 2010-03-01
12:37:35 UTC (rev 1913)
@@ -1,16 +1,16 @@
/**
* Copyright (C) 2009 eXo Platform SAS.
- *
+ *
* 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
@@ -36,6 +36,14 @@
public final static String FIRST_CHARACTER_NAME_VALIDATOR_REGEX =
"^[\\p{L}][\\p{L}._'\\- \\d]+$";
+
+ /**
+ * todo: move to common module
+ *
+ * @param separator
+ * @param strings
+ * @return
+ */
public static String join(String separator, String... strings)
{
if (strings == null)
@@ -65,6 +73,13 @@
return join(separator, array);
}
+ /**
+ * todo: move to common module
+ *
+ * @param separator
+ * @param s
+ * @return
+ */
public static String[] split(String separator, String s)
{
if (s == null)
@@ -130,13 +145,13 @@
/**
* Splits a string according to a string separator.
+ * <p/>
+ * The provided index defines the beginning of the splitted chunks in the returned
array. The values from the
+ * beginning up to the value index - 1 will be null values.
*
- * The provided index defines the beginning of the splitted chunks in the returned
array. The values
- * from the beginning up to the value index - 1 will be null values.
- *
* @param separator the string separator
- * @param index the index to which the chunks begin
- * @param s the string to split
+ * @param index the index to which the chunks begin
+ * @param s the string to split
* @return an array containing the splitted chunks plus extra leading pad
*/
public static String[] split(String separator, int index, String s)
Modified:
portal/trunk/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/mapping/MappedMap.java
===================================================================
---
portal/trunk/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/mapping/MappedMap.java 2010-03-01
12:31:01 UTC (rev 1912)
+++
portal/trunk/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/mapping/MappedMap.java 2010-03-01
12:37:35 UTC (rev 1913)
@@ -24,15 +24,12 @@
package org.gatein.portal.wsrp.state.mapping;
import org.exoplatform.commons.utils.Tools;
-import org.gatein.common.util.AbstractTypedMap;
import org.gatein.common.util.ParameterValidation;
-import javax.xml.namespace.QName;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
-import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -68,7 +65,7 @@
this.valueConverter = valueConverter;
int blacklistedNumber = blacklistedPropertyNames.length;
- if(blacklistedNumber > 0)
+ if (blacklistedNumber > 0)
{
blacklistedPropertyKeys = new
HashSet<String>(jcrBlacklistedPropertyKeys);
blacklistedPropertyKeys.addAll(Arrays.asList(blacklistedPropertyNames));
@@ -113,6 +110,7 @@
public static interface Converter<Internal, External>
{
External fromInternal(Internal internal);
+
Internal toInternal(External external);
}
}
Show replies by date