org.hibernate

Class FetchMode

Implemented Interfaces:
Serializable

public final class FetchMode
extends java.lang.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.
Author:
Gavin King
See Also:
Criteria.setFetchMode(java.lang.String, FetchMode)

Field Summary

static FetchMode
DEFAULT
Default to the setting configured in the mapping file.
static FetchMode
EAGER
Deprecated. use FetchMode.JOIN
static FetchMode
JOIN
Fetch using an outer join.
static FetchMode
LAZY
Deprecated. use FetchMode.SELECT
static FetchMode
SELECT
Fetch eagerly, using a separate select.

Method Summary

String
toString()

Field Details

DEFAULT

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

EAGER

public static final FetchMode EAGER

Deprecated. use FetchMode.JOIN

Fetch eagerly, using an outer join. Equivalent to outer-join="true".

JOIN

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

LAZY

public static final FetchMode LAZY

Deprecated. use FetchMode.SELECT

Fetch lazily. Equivalent to outer-join="false".

SELECT

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

Method Details

toString

public String toString()