Package org.apache.zookeeper.common
Class StringUtils
- java.lang.Object
-
- org.apache.zookeeper.common.StringUtils
-
public class StringUtils extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.String
joinStrings(java.util.List<java.lang.String> list, java.lang.String delim)
This method takes a Listand a delimiter and joins the strings into a single string, where the original strings are separated using the given delimiter. static java.util.List<java.lang.String>
split(java.lang.String value, java.lang.String separator)
This method returns an immutable List, but different from String's split() it trims the results in the input String, and removes any empty string from the resulting List.
-
-
-
Method Detail
-
split
public static java.util.List<java.lang.String> split(java.lang.String value, java.lang.String separator)
This method returns an immutable List, but different from String's split() it trims the results in the input String, and removes any empty string from the resulting List.
-
joinStrings
public static java.lang.String joinStrings(java.util.List<java.lang.String> list, java.lang.String delim)
This method takes a Listand a delimiter and joins the strings into a single string, where the original strings are separated using the given delimiter.
-
-