public enum NotFoundAction extends Enum<NotFoundAction>
Possible actions when an associated entity is not found in the database. Often seen with "legacy" foreign-key
schemes which do not use NULL
to indicate a missing reference, instead using a "magic value".
Enum Constant and Description |
---|
EXCEPTION
Raise an exception when an element is not found (default and recommended).
|
IGNORE
Ignore the element when not found in database.
|
Modifier and Type | Method and Description |
---|---|
static NotFoundAction |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static NotFoundAction[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final NotFoundAction EXCEPTION
Raise an exception when an element is not found (default and recommended).
public static final NotFoundAction IGNORE
Ignore the element when not found in database.
public static NotFoundAction[] values()
for (NotFoundAction c : NotFoundAction.values()) System.out.println(c);
public static NotFoundAction 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 nullCopyright © 2001-2018 Red Hat, Inc. All Rights Reserved.