/// <summary> /// 根据对象的主键,删除数据库记录 /// </summary> /// <param name="tableObject">含Mapping信息的对象</param> /// <returns>已执行处理的记录数</returns> public int Delete(Object tableObject) { Object2Delete obj2Delete = getObject2Delete(); obj2Delete.parse(tableObject); return(this.Execute(obj2Delete.AsSql(), obj2Delete.GetSqlParameterNames(), obj2Delete.GetSqlParameterValues())); }
private Object2Delete getObject2Delete() { if (this.obj2Delete == null) { this.obj2Delete = new Object2Delete(); } return(this.obj2Delete); }