Called when a transient entity is passed to SaveOrUpdate.

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

Syntax

C#
Nullable<bool> IsTransient(
	Object entity
)
Visual Basic
Function IsTransient ( _
	entity As Object _
) As Nullable(Of Boolean)
Visual C++
Nullable<bool> IsTransient(
	Object^ entity
)

Parameters

entity
Type: System..::..Object
A transient entity

Return Value

Boolean or nullNothingnullptra null reference (Nothing in Visual Basic) to choose default behaviour

Remarks

The return value determines if the object is saved trueTruetruetrue (True in Visual Basic) - the entity is passed to Save(), resulting in an INSERTfalseFalsefalsefalse (False in Visual Basic) - the entity is passed to Update(), resulting in an UPDATEnullNothingnullptra null reference (Nothing in Visual Basic) - Hibernate uses the unsaved-value mapping to determine if the object is unsaved

See Also