public static enum Assert.CmpObj extends Enum<Assert.CmpObj>
Assert.assertIs(Assert.CmpObj, Comparable, Object),
Assert.assertIs(Assert.CmpObj, Object, Object, Comparator)
and variants thereof.| Enum Constant and Description |
|---|
EQUAL |
GREATER |
GREATER_EQ |
LESS |
LESS_EQ |
NOT_EQUAL |
| Modifier and Type | Field and Description |
|---|---|
private String |
message
Core part of the message when the relation fails.
|
| Modifier and Type | Method and Description |
|---|---|
private boolean |
invokeCompareTo(Comparable<?> expected,
Object actual)
Returns
expected.compareTo(actual) if possible. |
(package private) abstract boolean |
isValid(int flag3)
Returns whether
isValid method here. |
static Assert.CmpObj |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Assert.CmpObj[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Assert.CmpObj LESS_EQ
public static final Assert.CmpObj LESS
public static final Assert.CmpObj GREATER
public static final Assert.CmpObj GREATER_EQ
public static final Assert.CmpObj EQUAL
public static final Assert.CmpObj NOT_EQUAL
private String message
public static Assert.CmpObj[] values()
for (Assert.CmpObj c : Assert.CmpObj.values()) System.out.println(c);
public static Assert.CmpObj valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullabstract boolean isValid(int flag3)
isValid method here.flag3 - an int which is the output
of a method Comparable.compareTo(T)
or Comparator.compare(T, T).boolean value
signifying whether flag3 is allowed.private boolean invokeCompareTo(Comparable<?> expected, Object actual)
expected.compareTo(actual) if possible.expected - an instance of an Object.actual - an Object or null.int value which results in invoking
expected.compare(actual).IllegalArgumentException - expected is not an instance
of Comparable
and in particular for expected == null,
expected.compareTo(actual)
raises an exception.
IllegalStateException - if expected.compare(actual) is evaluated
for actual == null without throwing an exception
as specified for Comparable.compareTo(T).Copyright © 2012–2018 Simuline Organization (l2r). All rights reserved.