public final class

CollectionUtils

extends Object
java.lang.Object
   ↳ com.atlassian.confluence.util.collections.CollectionUtils

Summary

Public Methods
static <T> T[] array(T... elements)
Return an array of the given elements.
static <T> List<T> list(T... elements)
Returns a List with the given elements.
static <T> Set<T> set(T... elements)
Returns a Set with the given elements.
[Expand]
Inherited Methods
From class java.lang.Object

Public Methods

public static T[] array (T... elements)

Return an array of the given elements.

Integer[] aryOfInts = array(1,2,3,4);

public static List<T> list (T... elements)

Returns a List with the given elements.

Returns
  • List, never returns null

public static Set<T> set (T... elements)

Returns a Set with the given elements.

 List<String> hs = list("s1", "s2");
 
Returns
  • Set, never returns null