Package com.google.common.collect
Class CollectPreconditions
java.lang.Object
com.google.common.collect.CollectPreconditions
Precondition checks useful in collection implementations.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static voidcheckEntryNotNull(Object key, Object value) (package private) static intcheckNonnegative(int value, String name) (package private) static longcheckNonnegative(long value, String name) (package private) static voidcheckPositive(int value, String name) (package private) static voidcheckRemove(boolean canRemove) Precondition tester forIterator.remove()that throws an exception with a consistent error message.
-
Constructor Details
-
CollectPreconditions
CollectPreconditions()
-
-
Method Details
-
checkEntryNotNull
-
checkNonnegative
-
checkNonnegative
-
checkPositive
-
checkRemove
static void checkRemove(boolean canRemove) Precondition tester forIterator.remove()that throws an exception with a consistent error message.
-