Package nz.org.riskscape.util
Class ListUtils
java.lang.Object
nz.org.riskscape.util.ListUtils
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> List<T>
Fluid, immutable list appending method that appends an element at the end of a given list, returning a new liststatic <T> List<T>
Fluid, immutable list concatenation method that concatenates two lists, returning a new list with the contents of list1 and list2 appended in order.static <T> List<T>
Fluid, immutable list prepending method that prepends the given element to the given list, returning a new liststatic <T> List<T>
prepend
(T element, T... rest) Fluid, immutable list prepending method that prepends the given element to the given list, returning a new list
-
Constructor Details
-
ListUtils
public ListUtils()
-
-
Method Details
-
concat
Fluid, immutable list concatenation method that concatenates two lists, returning a new list with the contents of list1 and list2 appended in order.
-
append
Fluid, immutable list appending method that appends an element at the end of a given list, returning a new list
-
prepend
Fluid, immutable list prepending method that prepends the given element to the given list, returning a new list
-
prepend
Fluid, immutable list prepending method that prepends the given element to the given list, returning a new list
-