public void Clone <T>(T obj) where T : class, IModel { TallyMaster objdata = obj as TallyMaster; this.RecNo = objdata.RecNo; this.TallyTag = objdata.TallyTag; this.AccountCode = objdata.AccountCode; this.VAT = objdata.VAT; this.TallyLedger = objdata.TallyLedger; this.TallyVATLedger = objdata.TallyVATLedger; this.TallyClass = objdata.TallyClass; this.CUser = objdata.CUser; this.CDateTime = objdata.CDateTime; this.EUser = objdata.EUser; this.EDateTime = objdata.EDateTime; this.CreatedBy = objdata.CreatedBy; this.CreatedDate = objdata.CreatedDate; this.UpdateddBy = objdata.UpdateddBy; this.UpdatedDate = objdata.UpdatedDate; this.UpdatedCount = objdata.UpdatedCount; this.LUT = objdata.LUT; }
public T Copy <T>() where T : class, IModel, new() { T obj = new T(); TallyMaster objdata = obj as TallyMaster; objdata.RecNo = this.RecNo; objdata.TallyTag = this.TallyTag; objdata.AccountCode = this.AccountCode; objdata.VAT = this.VAT; objdata.TallyLedger = this.TallyLedger; objdata.TallyVATLedger = this.TallyVATLedger; objdata.TallyClass = this.TallyClass; objdata.CUser = this.CUser; objdata.CDateTime = this.CDateTime; objdata.EUser = this.EUser; objdata.EDateTime = this.EDateTime; objdata.CreatedBy = this.CreatedBy; objdata.CreatedDate = this.CreatedDate; objdata.UpdateddBy = this.UpdateddBy; objdata.UpdatedDate = this.UpdatedDate; objdata.UpdatedCount = this.UpdatedCount; objdata.LUT = this.LUT; return(obj); }