join

public static String join(Object[]array)

Joins the elements of the provided array into a single String
containing the provided list of elements.

No separator is added to the joined String.
Null objects or empty strings within the array are represented by
empty strings.

 StringUtils.join(null)            = null
 StringUtils.join([])              = ""
 StringUtils.join([null])          = ""
 StringUtils.join(["a", "b", "c"]) = "abc"
 StringUtils.join([null, "", "a"]) = "a"
 

发表回复