Saves the instance to the database and flushes the session. If the primary key is unitialized it creates the instance on the database. Otherwise it updates it.

If the primary key is assigned, then you must invoke Create(Object) or Update(Object) instead.

Namespace: Castle.ActiveRecord
Assembly:  Castle.ActiveRecord (in Castle.ActiveRecord.dll)
Version: 1.0.3.0

Syntax

C#
public static void SaveAndFlush(
	Object instance
)

Parameters

instance
Object
The ActiveRecord instance to be saved

See Also