Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions documentation/src/main/asciidoc/introduction/Interacting.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -1067,7 +1067,7 @@ List<Book> matchingBooks = query.getResultList();

Notice that:

- The link:{doc-javadoc-url}org/hibernate/query/Restriction.html[`Restriction`] interface has static methods for constructing a variety of different kinds of restriction in a completely typesafe way.
- The link:{doc-javadoc-url}org/hibernate/query/restriction/Restriction.html[`Restriction`] interface has static methods for constructing a variety of different kinds of restriction in a completely typesafe way.
- Similarly, the link:{doc-javadoc-url}org/hibernate/query/Order.html[`Order`] class has a variety of static methods for constructing different kinds of ordering criteria.

We need the following methods of `SelectionQuery`:
Expand All @@ -1085,7 +1085,7 @@ Unfortunately, `Restriction` and `Order` can't be used with JPA's `TypedQuery` i

Alternatively, `Restriction` and `Order` can be used with <<paging-and-ordering,generated query or finder methods>>, and even with link:{doc-data-repositories-url}[Jakarta Data repositories].

The interface link:{doc-javadoc-url}org/hibernate/query/Path.html[`Path`] may be used to express restrictions on fields of an embedded or associated entity class.
The interface link:{doc-javadoc-url}org/hibernate/query/restriction/Path.html[`Path`] may be used to express restrictions on fields of an embedded or associated entity class.

[source,java]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@
* </ul>
* <p>
* Finally, a method might have a parameter of type
* {@link org.hibernate.query.Restriction Restriction<? super E>},
* {@link org.hibernate.query.restriction.Restriction Restriction<? super E>},
* allowing the caller to apply an arbitrary filtering criterion to
* the query results.
* <p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@
* </ul>
* <p>
* Finally, a method might have a parameter of type
* {@link org.hibernate.query.Restriction Restriction<? super E>},
* {@link org.hibernate.query.restriction.Restriction Restriction<? super E>},
* allowing the caller to apply an arbitrary filtering criterion to
* the query results.
* <p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
*
* @see SelectionQuery#setOrder(Order)
* @see SelectionQuery#setOrder(java.util.List)
* @see Restriction
* @see org.hibernate.query.restriction.Restriction
*
* @author Gavin King
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import org.hibernate.dialect.Dialect;
import org.hibernate.graph.GraphSemantic;
import org.hibernate.graph.RootGraph;
import org.hibernate.query.restriction.Restriction;
import org.hibernate.query.spi.QueryOptions;
import org.hibernate.transform.ResultTransformer;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
import jakarta.persistence.TemporalType;
import org.hibernate.engine.profile.DefaultFetchProfile;
import org.hibernate.graph.GraphSemantic;
import org.hibernate.query.restriction.Restriction;

/**
* Within the context of an active {@linkplain org.hibernate.Session session},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import jakarta.persistence.criteria.Predicate;
import org.hibernate.Incubating;
import org.hibernate.Internal;
import org.hibernate.query.Restriction;

import java.util.List;

Expand All @@ -22,7 +21,7 @@
*
* @param <U> The type of the value being restricted
*
* @see Restriction
* @see org.hibernate.query.restriction.Restriction
*
* @author Gavin King
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.Root;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.Root;
import jakarta.persistence.metamodel.SingularAttribute;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.Root;
import jakarta.persistence.metamodel.SingularAttribute;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.Root;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
import jakarta.persistence.criteria.Root;
import jakarta.persistence.metamodel.SingularAttribute;
import org.hibernate.Incubating;
import org.hibernate.Internal;
import org.hibernate.query.Order;
import org.hibernate.query.SelectionQuery;
import org.hibernate.query.range.Range;

import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* SPDX-License-Identifier: LGPL-2.1-or-later
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.query;
package org.hibernate.query.restriction;

import jakarta.persistence.criteria.CriteriaBuilder;
import jakarta.persistence.criteria.Predicate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
import org.hibernate.query.Order;
import org.hibernate.query.Query;
import org.hibernate.query.QueryParameter;
import org.hibernate.query.Restriction;
import org.hibernate.query.restriction.Restriction;
import org.hibernate.query.ResultListTransformer;
import org.hibernate.query.TupleTransformer;
import org.hibernate.query.named.NamedQueryMemento;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
import org.hibernate.query.PathException;
import org.hibernate.query.Query;
import org.hibernate.query.QueryParameter;
import org.hibernate.query.Restriction;
import org.hibernate.query.restriction.Restriction;
import org.hibernate.query.ResultListTransformer;
import org.hibernate.query.TupleTransformer;
import org.hibernate.query.internal.DelegatingDomainQueryExecutionContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import org.hibernate.query.Order;
import org.hibernate.query.Page;
import org.hibernate.query.QueryLogging;
import org.hibernate.query.Restriction;
import org.hibernate.query.restriction.Restriction;
import org.hibernate.query.SelectionQuery;
import org.hibernate.query.criteria.JpaSelection;
import org.hibernate.query.hql.internal.NamedHqlQueryMementoImpl;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
import org.hibernate.query.Page;
import org.hibernate.query.Query;
import org.hibernate.query.QueryParameter;
import org.hibernate.query.Restriction;
import org.hibernate.query.restriction.Restriction;
import org.hibernate.query.ResultListTransformer;
import org.hibernate.query.TupleTransformer;
import org.hibernate.query.criteria.internal.NamedCriteriaQueryMementoImpl;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
import org.hibernate.query.ParameterMetadata;
import org.hibernate.query.QueryFlushMode;
import org.hibernate.query.QueryParameter;
import org.hibernate.query.Restriction;
import org.hibernate.query.restriction.Restriction;
import org.hibernate.query.spi.QueryOptions;
import org.hibernate.query.sqm.SqmSelectionQuery;
import org.hibernate.query.sqm.tree.SqmStatement;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@

import static org.hibernate.query.Order.asc;
import static org.hibernate.query.Order.desc;
import static org.hibernate.query.Path.from;
import static org.hibernate.query.Restriction.all;
import static org.hibernate.query.Restriction.any;
import static org.hibernate.query.Restriction.between;
import static org.hibernate.query.Restriction.contains;
import static org.hibernate.query.Restriction.endsWith;
import static org.hibernate.query.Restriction.equal;
import static org.hibernate.query.Restriction.equalIgnoringCase;
import static org.hibernate.query.Restriction.greaterThan;
import static org.hibernate.query.Restriction.in;
import static org.hibernate.query.Restriction.like;
import static org.hibernate.query.Restriction.restrict;
import static org.hibernate.query.Restriction.unrestricted;
import static org.hibernate.query.restriction.Path.from;
import static org.hibernate.query.restriction.Restriction.all;
import static org.hibernate.query.restriction.Restriction.any;
import static org.hibernate.query.restriction.Restriction.between;
import static org.hibernate.query.restriction.Restriction.contains;
import static org.hibernate.query.restriction.Restriction.endsWith;
import static org.hibernate.query.restriction.Restriction.equal;
import static org.hibernate.query.restriction.Restriction.equalIgnoringCase;
import static org.hibernate.query.restriction.Restriction.greaterThan;
import static org.hibernate.query.restriction.Restriction.in;
import static org.hibernate.query.restriction.Restriction.like;
import static org.hibernate.query.restriction.Restriction.restrict;
import static org.hibernate.query.restriction.Restriction.unrestricted;
import static org.hibernate.query.range.Range.containing;
import static org.hibernate.query.range.Range.greaterThan;
import static org.hibernate.query.range.Range.singleCaseInsensitiveValue;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ public final class Constants {
public static final String HIB_KEYED_PAGE = "org.hibernate.query.KeyedPage";
public static final String HIB_KEYED_RESULT_LIST = "org.hibernate.query.KeyedResultList";
public static final String HIB_SORT_DIRECTION = "org.hibernate.query.SortDirection";
public static final String HIB_RESTRICTION = "org.hibernate.query.Restriction";
public static final String HIB_RESTRICTION = "org.hibernate.query.restriction.Restriction";
public static final String HIB_RANGE = "org.hibernate.query.range.Range";

public static final String CHECK_HQL = "org.hibernate.annotations.processing.CheckHQL";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import org.hibernate.annotations.processing.Find;
import org.hibernate.annotations.processing.HQL;
import org.hibernate.query.Order;
import org.hibernate.query.Restriction;
import org.hibernate.query.restriction.Restriction;
import org.hibernate.query.range.Range;

import java.util.List;
Expand Down
Loading