public abstract class Misc
extends java.lang.Object
Constructor and Description |
---|
Misc() |
Modifier and Type | Method and Description |
---|---|
static <T> boolean |
addNoDuplicates(java.util.List<T> list,
T candidate)
Add an item to a list, checking for duplicates.
|
static <T> boolean |
isEqual(T object1,
T object2)
Determine if two objects of the same type are equal or not.
|
static boolean |
isZero(long[] values,
int columnCount)
Determine if all the values in an array are zero or not.
|
public static <T> boolean isEqual(T object1, T object2)
T
- The type of object being compared.object1
- Left hand side object.object2
- Right hand side object.public static <T> boolean addNoDuplicates(java.util.List<T> list, T candidate)
T
- The type of object contained by list
.list
- The list to add the item to.candidate
- The candidate item.public static boolean isZero(long[] values, int columnCount)
values
- The array to check.columnCount
- Number of array values to check