Class CollectionUtils
- java.lang.Object
-
- com.sun.enterprise.universal.collections.CollectionUtils
-
public class CollectionUtils extends Object
all-static methods for handling operations with Collections- Author:
- bnevins
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Map<String,String>propertiesToStringMap(Properties p)Convert a Properties object, which is a Mapstatic StringtoString(String[] arr)Convert a String[] into a space-delimited Stringstatic StringtoString(List<String> list)Convert a List of String into a space-delimited Stringstatic StringtoString(Map<String,String> map)Tired of dumping a String representation of a Map? Then call me!static String[]toStringArray(Map<String,String> map)static StringtoStringLines(String[] arr)Convert a String[] into a newline-delimited String
-
-
-
Method Detail
-
propertiesToStringMap
public static Map<String,String> propertiesToStringMap(Properties p)
Convert a Properties object, which is a Map- Parameters:
p- The Properties object to convert- Returns:
- The converted Map
-
toString
public static String toString(Map<String,String> map)
Tired of dumping a String representation of a Map? Then call me!- Parameters:
map- The map to turn into a printable String- Returns:
- The pretty String
-
toString
public static String toString(String[] arr)
Convert a String[] into a space-delimited String- Parameters:
arr- The String array to convert- Returns:
- The pretty String
-
toStringLines
public static String toStringLines(String[] arr)
Convert a String[] into a newline-delimited String- Parameters:
arr- The String array to convert- Returns:
- The pretty String
-
toString
public static String toString(List<String> list)
Convert a List of String into a space-delimited String- Parameters:
arr- The String array to convert- Returns:
- The pretty String
-
-