Represents a fetching strategy.

Namespace: NHibernate
Assembly: NHibernate (in NHibernate.dll) Version: 3.2.0.4000 (3.2.0.4000)

Syntax

C#
[SerializableAttribute]
public enum FetchMode
Visual Basic
<SerializableAttribute> _
Public Enumeration FetchMode
Visual C++
[SerializableAttribute]
public enum class FetchMode

Members

Member nameValueDescription
Default0 Default to the setting configured in the mapping file.
Select1 Fetch eagerly, using a separate select. Equivalent to fetch="select" (and outer-join="false")
Join2 Fetch using an outer join. Equivalent to fetch="join" (and outer-join="true")
Lazy1
Eager2
IsIn Apply an "in" constraint to the named property Note: throws an exception outside of a QueryOver expression
IsIn Apply an "in" constraint to the named property Note: throws an exception outside of a QueryOver expression
IsBetween Apply a "between" constraint to the named property Note: throws an exception outside of a QueryOver expression
IsProxy
As
ToTypeParameters

Remarks

This is used together with the ICriteria API to specify runtime fetching strategies.

For Hql queries, use the FETCH keyword instead.

See Also