Create a new ICriteria instance, for the given entity name, with the given alias.

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

Syntax

C#
public ICriteria CreateCriteria(
	string entityName,
	string alias
)
Visual Basic
Public Function CreateCriteria ( _
	entityName As String, _
	alias As String _
) As ICriteria
Visual C++
public:
virtual ICriteria^ CreateCriteria(
	String^ entityName, 
	String^ alias
) sealed

Parameters

entityName
Type: System..::..String
The entity name.
alias
Type: System..::..String
The alias of the entity

Return Value

The ICriteria.

Implements

IStatelessSession..::..CreateCriteria(String, String)

Remarks

Entities returned by the query are detached.

See Also