Debian Codegraph @

lang/java/src/com/sleepycat/persist/model/DeleteAction.java

raw
1 /*-
2 * See the file LICENSE for redistribution information.
3 *
4 * Copyright (c) 2002, 2013 Oracle and/or its affiliates. All rights reserved.
5 *
6 */
7
8 package com.sleepycat.persist.model;
9
10
11 /**
12 * Specifies the action to take when a related entity is deleted having a
13 * primary key value that exists as a secondary key value for this entity.
14 * This can be specified using a {@link SecondaryKey#onRelatedEntityDelete}
15 * annotation.
16 *
17 * @author Mark Hayes
18 */
19 public enum DeleteAction {
20
21 /**
22 * The default action, {@code ABORT}, means that an exception is thrown in
23 * order to abort the current transaction.
24 */
25 ABORT,
26
27 /**
28 * If {@code CASCADE} is specified, then this entity will be deleted also,
29 * which could in turn trigger further deletions, causing a cascading
30 * effect.
31 */
32 CASCADE,
33
34 /**
35 * If {@code NULLIFY} is specified, then the secondary key in this entity
36 * is set to null and this entity is updated. For a secondary key field
37 * that has an array or collection type, the array or collection element
38 * will be removed by this action. The secondary key field must have a
39 * reference (not a primitive) type in order to specify this action.
40 */
41 NULLIFY;
42 }