From 31480aa1c8b181bafaf24a572986acbac05d6f76 Mon Sep 17 00:00:00 2001 From: Brett Meyer Date: Mon, 7 Jan 2013 12:17:24 -0500 Subject: [PATCH] HHH-7797 Deprecating mistakenly removed Dialect methods --- .../java/org/hibernate/dialect/Dialect.java | 45 +++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/hibernate-core/src/main/java/org/hibernate/dialect/Dialect.java b/hibernate-core/src/main/java/org/hibernate/dialect/Dialect.java index dcaf3e5038..8d1871c488 100644 --- a/hibernate-core/src/main/java/org/hibernate/dialect/Dialect.java +++ b/hibernate-core/src/main/java/org/hibernate/dialect/Dialect.java @@ -2385,4 +2385,49 @@ public abstract class Dialect implements ConversionContext { public String getNotExpression( String expression ) { return "not " + expression; } + + /** + * Does this dialect support the UNIQUE column syntax? + * + * @return boolean + * + * @deprecated {@link #getUniqueDelegate()} should be overridden instead. + */ + @Deprecated + public boolean supportsUnique() { + return true; + } + + /** + * Does this dialect support adding Unique constraints via create and alter table ? + * + * @return boolean + * + * @deprecated {@link #getUniqueDelegate()} should be overridden instead. + */ + @Deprecated + public boolean supportsUniqueConstraintInCreateAlterTable() { + return true; + } + + /** + * The syntax used to add a unique constraint to a table. + * + * @param constraintName The name of the unique constraint. + * @return The "add unique" fragment + * + * @deprecated {@link #getUniqueDelegate()} should be overridden instead. + */ + @Deprecated + public String getAddUniqueConstraintString(String constraintName) { + return " add constraint " + constraintName + " unique "; + } + + /** + * @deprecated {@link #getUniqueDelegate()} should be overridden instead. + */ + @Deprecated + public boolean supportsNotNullUnique() { + return true; + } }