public enum WhenToCheckConstraint extends Enum<WhenToCheckConstraint> implements Enumeration
StoppingConditionConstraint
should be checked.
Since the stopping conditions
are usually
numerically sampled, there is a moment when an event is detected, but not exactly found to
within tolerance.Enum Constant and Description |
---|
AT_EXACT_EVENT
Check when an exact event has been found.
|
WHEN_EVENT_IS_DETECTED
Check when an event is detected.
|
Modifier and Type | Method and Description |
---|---|
static WhenToCheckConstraint |
getDefault()
Get the enum constant that is considered to be the default.
|
static WhenToCheckConstraint |
getFromValue(int value)
Get the enum constant that is associated with the given numeric value.
|
int |
getValue()
Get the numeric value associated with this enum constant.
|
static WhenToCheckConstraint |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static WhenToCheckConstraint[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final WhenToCheckConstraint AT_EXACT_EVENT
constraint
result may change between when an
event is detected and when it is exactly found, then checking the
constraints
at the exact event
will be more robust than checking when it is detected.public static final WhenToCheckConstraint WHEN_EVENT_IS_DETECTED
constraint
is not likely to be near its critical
value when the condition
is, then checking when a
event is detected should prevent the stopping condition function from honing in on an exact event
which can improve performance.public static WhenToCheckConstraint[] values()
for (WhenToCheckConstraint c : WhenToCheckConstraint.values()) System.out.println(c);
public static WhenToCheckConstraint 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 nullpublic int getValue()
getValue
in interface Enumeration
@Nonnull public static WhenToCheckConstraint getFromValue(int value)
value
- a numeric value.@Nonnull public static WhenToCheckConstraint getDefault()