From 998b8cc1927283d34fb214fdf5b46b3757c275a3 Mon Sep 17 00:00:00 2001 From: rob bygrave Date: Fri, 15 May 2020 14:06:28 +1200 Subject: [PATCH] #2011 - Change query.orderBy() to not be deprecated --- src/main/java/io/ebean/Query.java | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/src/main/java/io/ebean/Query.java b/src/main/java/io/ebean/Query.java index ac2b246a2..aa5bbf596 100644 --- a/src/main/java/io/ebean/Query.java +++ b/src/main/java/io/ebean/Query.java @@ -1352,9 +1352,13 @@ public interface Query { Query having(Expression addExpressionToHaving); /** - * Deprecated migrate to {@link #order(String)} + * Set the order by clause replacing the existing order by clause if there is + * one. + *

+ * This follows SQL syntax using commas between each property with the + * optional asc and desc keywords representing ascending and descending order + * respectively. */ - @Deprecated Query orderBy(String orderByClause); /** @@ -1373,13 +1377,20 @@ public interface Query { *

* This will never return a null. If no order by clause exists then an 'empty' * OrderBy object is returned. + *

+ * This is the same as orderBy() */ OrderBy order(); /** - * Deprecated migrate to order(). + * Return the OrderBy so that you can append an ascending or descending + * property to the order by clause. + *

+ * This will never return a null. If no order by clause exists then an 'empty' + * OrderBy object is returned. + *

+ * This is the same as order() */ - @Deprecated OrderBy orderBy(); /** @@ -1388,9 +1399,8 @@ public interface Query { Query setOrder(OrderBy orderBy); /** - * Deprecated migrate to {@link #setOrder(OrderBy)} + * Set an OrderBy object to replace any existing OrderBy clause. */ - @Deprecated Query setOrderBy(OrderBy orderBy); /**