コード例 #1
0
        public Esbnoun BuildFromRow(DataRow row)
        {
            var returnRecord = Esbnoun.BuildEsbnounFromRow(row);

            returnRecord = this.BuildExtraFromRow <Esbnoun>(returnRecord, row);
            return(returnRecord);
        }
コード例 #2
0
        public Esbnoun Insert(Esbnoun record)
        {
            DataRow row = this.dataSet.ttblesbnoun.NewttblesbnounRow();

            this.UpdateToRow(ref row, record);
            this.ExtraUpdateToRow(ref row, record);
            this.dataSet.ttblesbnoun.AddttblesbnounRow((pdsesbnounDataSet.ttblesbnounRow)row);
            this.SaveChanges();
            return(this.dataSet.ttblesbnoun.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblesbnoun.Rows[0]) : null);
        }
コード例 #3
0
        public Esbnoun GetByRowId(string rowId, string fldList)
        {
            var     row     = this.GetRowByRowId(rowId, fldList);
            Esbnoun esbnoun = null;

            if (row != null)
            {
                esbnoun = this.BuildFromRow(row);
            }
            return(esbnoun);
        }
コード例 #4
0
        protected Esbnoun Fetch(string where, int batchsize, string fldList)
        {
            this.FetchWhere(where, batchsize, fldList);
            var     row     = this.dataSet.ttblesbnoun.AsEnumerable().SingleOrDefault();
            Esbnoun esbnoun = null;

            if (row != null)
            {
                esbnoun = this.BuildFromRow(row);
            }
            return(esbnoun);
        }
コード例 #5
0
        public void Delete(Esbnoun record)
        {
            var row = this.GetRowByRowId(record.rowID, string.Empty);

            if (row == null)
            {
                row = this.dataSet.ttblesbnoun.NewttblesbnounRow();
                Esbnoun.BuildMinimalRow(ref row, record);
                this.dataSet.ttblesbnoun.AddttblesbnounRow((pdsesbnounDataSet.ttblesbnounRow)row);
            }
            row.Delete();
            this.SaveChanges();
        }
コード例 #6
0
        public Esbnoun Update(Esbnoun record)
        {
            var row = this.GetRowByRowId(record.rowID, string.Empty);

            if (row != null)
            {
                this.UpdateToRow(ref row, record);
                this.ExtraUpdateToRow(ref row, record);
                this.SaveChanges();
                return(this.dataSet.ttblesbnoun.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblesbnoun.Rows[0]) : null);
            }
            ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421);
            return(null);
        }
コード例 #7
0
 public void Delete(Esbnoun record)
 {
     this.adapter.Delete(record);
 }
コード例 #8
0
 public Esbnoun Update(Esbnoun record)
 {
     return(this.adapter.Update(record));
 }
コード例 #9
0
 public Esbnoun Insert(Esbnoun record)
 {
     return(this.adapter.Insert(record));
 }
コード例 #10
0
 public void UpdateToRow(ref DataRow row, Esbnoun record)
 {
     Esbnoun.UpdateRowFromEsbnoun(ref row, record);
     this.ExtraUpdateToRow(ref row, record);
 }
コード例 #11
0
 public Esbnoun Insert(Esbnoun record)
 {
     return(this.repository.Insert(record));
 }
コード例 #12
0
 public void Delete(Esbnoun record)
 {
     this.repository.Delete(record);
 }
コード例 #13
0
 public Esbnoun Update(Esbnoun record)
 {
     return(this.repository.Update(record));
 }