Package net.sf.paperclips.internal
Class Util
java.lang.Object
net.sf.paperclips.internal.Util
General use convenience methods: null checking, equality
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
equal
(double left, double right) Returns whether the arguments are equal.static boolean
Returns whether the arguments are equal.static void
Triggers a SWT.ERROR_NULL_ARGUMENT exception if the argument or any of its elements is null.static void
Triggers a SWT.ERROR_NULL_ARGUMENT exception if the argument or any of its elements is null.static void
Triggers a SWT.ERROR_NULL_ARGUMENT exception if the argument is null.static void
Triggers a SWT.ERROR_NULL_ARGUMENT exception if any argument is null.static void
Triggers a SWT.ERROR_NULL_ARGUMENT exception if any argument is null.static boolean
Returns whether the objects are of the same class.
-
Constructor Details
-
Util
public Util()
-
-
Method Details
-
sameClass
Returns whether the objects are of the same class.- Parameters:
left
- object to testright
- object to test- Returns:
- whether the objects are of the same class.
-
equal
Returns whether the arguments are equal.- Parameters:
left
- object to testright
- object to test- Returns:
- whether the arguments are equal.
-
equal
public static boolean equal(double left, double right) Returns whether the arguments are equal.- Parameters:
left
- double value to testright
- double value to test- Returns:
- whether the arguments are equal.
-
noNulls
Triggers a SWT.ERROR_NULL_ARGUMENT exception if the argument or any of its elements is null.- Parameters:
list
- a list to test for null elements.
-
noNulls
Triggers a SWT.ERROR_NULL_ARGUMENT exception if the argument or any of its elements is null.- Parameters:
objs
- an array to test for null elements.
-
notNull
Triggers a SWT.ERROR_NULL_ARGUMENT exception if the argument is null.- Parameters:
obj
- the object to test for null.
-
notNull
Triggers a SWT.ERROR_NULL_ARGUMENT exception if any argument is null.- Parameters:
o1
- an object to test for null.o2
- an object to test for null.
-
notNull
Triggers a SWT.ERROR_NULL_ARGUMENT exception if any argument is null.- Parameters:
o1
- an object to test for null.o2
- an object to test for null.o3
- an object to test for null.
-