Microsoft.Isam.Esent.Interop.Update.Update C# (CSharp) Method

Update() public method

Initializes a new instance of the Update class. This automatically begins an update. The update will be cancelled if not explicitly saved.
public Update ( JET_SESID sesid, JET_TABLEID tableid, JET_prep prep ) : System
sesid JET_SESID The session to start the transaction for.
tableid JET_TABLEID The tableid to prepare the update for.
prep JET_prep The type of update.
return System
        public Update(JET_SESID sesid, JET_TABLEID tableid, JET_prep prep)
        {
            if (JET_prep.Cancel == prep)
            {
                throw new ArgumentException("Cannot create an Update for JET_prep.Cancel", "prep");
            }

            this.sesid = sesid;
            this.tableid = tableid;
            Api.JetPrepareUpdate(this.sesid, this.tableid, prep);
            this.ResourceWasAllocated();
        }