File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed
hibernate-core/src/main/java/org/hibernate/id/insert Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change 22
22
*/
23
23
public interface InsertGeneratedIdentifierDelegate {
24
24
25
+ /**
26
+ * Build a {@link org.hibernate.sql.Insert} specific to the delegate's mode
27
+ * of handling generated key values.
28
+ *
29
+ * @return The insert object.
30
+ * @deprecated Implement {@link #prepareIdentifierGeneratingInsert(SqlStringGenerationContext)} instead.
31
+ */
32
+ @ Deprecated
33
+ default IdentifierGeneratingInsert prepareIdentifierGeneratingInsert () {
34
+ throw new IllegalStateException ("prepareIdentifierGeneratingInsert(...) was not implemented!" );
35
+ }
36
+
25
37
/**
26
38
* Build a {@link org.hibernate.sql.Insert} specific to the delegate's mode
27
39
* of handling generated key values.
28
40
*
29
41
* @param context A context to help generate SQL strings
30
42
* @return The insert object.
31
43
*/
32
- IdentifierGeneratingInsert prepareIdentifierGeneratingInsert (SqlStringGenerationContext context );
44
+ default IdentifierGeneratingInsert prepareIdentifierGeneratingInsert (SqlStringGenerationContext context ) {
45
+ return prepareIdentifierGeneratingInsert ();
46
+ }
33
47
34
48
/**
35
49
* Perform the indicated insert SQL statement and determine the identifier value
You can’t perform that action at this time.
0 commit comments