protected void AssertFlagsAfterDelete(RowBase obj) { Assert.AreEqual(obj.IsSavedˡ, true); Assert.AreEqual(obj.IsDeletedˡ, true); Assert.AreEqual(obj.IsDirtyˡ, false); Assert.AreEqual(obj.IsFromDatabaseˡ, true); Assert.AreEqual(obj.MarkForDeletionˡ, false); }
public CodeGenException(string message, Exception innerException, string sql, List <SqlParameter> parameters, RowBase obj) : base(message, innerException) { _sql = sql ?? ""; _rowBase = obj; _parameters = parameters; StringBuilder bob = new StringBuilder(); bob.Append(this.GetType().ToString()); bob.Append("\n"); bob.Append(message ?? ""); bob.Append("\n"); if (_rowBase != null) { bob.Append("object: "); bob.Append(_rowBase.GetType().ToString()); bob.Append("\n"); } if (_sql.Length > 0) { bob.Append("sql: "); bob.Append(_sql); bob.Append("\n"); } _myMessage = "\n" + bob.ToString().Trim() + "\n"; CodeGenEtc.DebugMessage("======================================================================================"); CodeGenEtc.DebugMessage("CODEGEN EXCEPTION"); CodeGenEtc.DebugMessage(_myMessage.Trim()); CodeGenEtc.DebugMessage("--------------------------------------------------------------------------------------"); if (innerException != null) { CodeGenEtc.DebugMessage(innerException.ToString()); } CodeGenEtc.DebugMessage("======================================================================================"); CodeGenEtc.DebugMessage("======================================================================================\n"); }
public CodeGenLoadException(string message, Exception innerException, string sql, List <SqlParameter> parameters, RowBase obj) : base(message, innerException, sql, parameters, obj) { }