Session: Saving changes
Pending session operations e.g. Store
, Delete
and many others will not be send to server till SaveChanges
is called.
Syntax
void SaveChanges();
Example
// storing new entity
session.Store(new Employee
{
FirstName = "John",
LastName = "Doe"
});
session.SaveChanges();