Return the persistent instance of the given entity class with the given identifier, or null if there is no such persistent instance. (If the instance, or a proxy for the instance, is already associated with the session, return that instance or proxy.)

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

Syntax

Visual Basic (Declaration)
Function Get ( _
	clazz As Type, _
	id As Object _
) As Object
C#
Object Get(
	Type clazz,
	Object id
)
Visual C++
Object^ Get(
	Type^ clazz, 
	Object^ id
)
JavaScript
function get(clazz, id);

Parameters

clazz
Type: System..::.Type
a persistent class
id
Type: System..::.Object
an identifier

Return Value

a persistent instance or null

See Also