Save() публичный Метод

Saves the instance information to the database. May Create or Update the instance depending on whether it has a valid ID.
If within a SessionScope the operation is going to be on hold until NHibernate (or you) decides to flush the session.
public Save ( ) : void
Результат void
Пример #1
0
 /// <summary>
 /// Saves the instance to the database
 /// </summary>
 /// <param name="instance">The ActiveRecord instance to be deleted</param>
 public static void Save(object instance)
 {
     ActiveRecordBase.Save(instance);
 }
Пример #2
0
 public virtual void Save()
 {
     ActiveRecordBase.Save(this);
 }
Пример #3
0
 /// <summary>
 /// Saves the instance to the database. If the primary key is unitialized
 /// it creates the instance on the database. Otherwise it updates it.
 /// <para>
 /// If the primary key is assigned, then you must invoke <see cref="Create"/>
 /// or <see cref="Update"/> instead.
 /// </para>
 /// </summary>
 /// <param name="instance">The ActiveRecord instance to be saved</param>
 protected internal static void Save(T instance)
 {
     ActiveRecordBase.Save(instance);
 }