Package org.hibernate

Class FetchMode

java.lang.Object
org.hibernate.FetchMode
All Implemented Interfaces:
Serializable

public final class FetchMode extends Object implements Serializable
Represents an association fetching strategy. This is used together with the Criteria API to specify runtime fetching strategies.

For HQL queries, use the FETCH keyword instead.
See Also:
  • Field Details

    • DEFAULT

      public static final FetchMode DEFAULT
      Default to the setting configured in the mapping file.
    • JOIN

      public static final FetchMode JOIN
      Fetch using an outer join. Equivalent to fetch="join".
    • SELECT

      public static final FetchMode SELECT
      Fetch eagerly, using a separate select. Equivalent to fetch="select".
    • LAZY

      public static final FetchMode LAZY
      Deprecated.
      use FetchMode.SELECT
      Fetch lazily. Equivalent to outer-join="false".
    • EAGER

      public static final FetchMode EAGER
      Deprecated.
      use FetchMode.JOIN
      Fetch eagerly, using an outer join. Equivalent to outer-join="true".
  • Method Details