/// <summary> /// Resets all property values to the state of the previous <see cref="Insert"/>, <see cref="Update"/> or <see cref="SaveVersion"/> specified by /// the <paramref name="steps"/> parameter. /// </summary> /// <param name="steps">The number of steps in history to undo.</param> /// <returns><see langword="true"/> if the operation was successful; otherwise <see langword="false"/>.</returns> public bool Undo(int steps) { return(DataRecordVersions.Undo(steps)); }
/// <summary> /// Resets all property values to the state of the previous <see cref="Insert"/>, <see cref="Update"/> or <see cref="SaveVersion"/>. /// </summary> /// <returns><see langword="true"/> if the operation was successful; otherwise <see langword="false"/>.</returns> internal bool Undo() { return(DataRecordVersions.Undo(1)); }
/// <summary> /// Initializes a new instance of the <see cref="DataRecord{TDataRecord}"/> class. /// </summary> protected DataRecord() { versions = new DataRecordVersions <TDataRecord>(Properties, this); }
/// <summary> /// Saves the current property values to history. /// </summary> /// <returns>An <see cref="int"/> representing the current number of steps in history.</returns> public int SaveVersion() { return(DataRecordVersions.Version()); }