public DrMedicineTmp GetObjectByKey(object keypair) { if (this.Contains(GetKey(keypair)) == false) { return(null); } DrMedicineTmp ob = this[GetKey(keypair)]; return((DrMedicineTmp)ob); }
public DrMedicineTmp GetObjectByKey(long k_DrMedTmpID) { if (this.Contains(GetKey(k_DrMedTmpID)) == false) { return(null); } DrMedicineTmp ob = this[GetKey(k_DrMedTmpID)]; return((DrMedicineTmp)ob); }
public DrMedicineTmp GetObjectByKey(KeyValuePair <string, long> keypair) { if (this.Contains(keypair) == false) { return(null); } DrMedicineTmp ob = this[keypair]; return((DrMedicineTmp)ob); }
public bool ChangeItem(KeyValuePair <string, long> keypair, DrMedicineTmp item) { DrMedicineTmp orig = this.GetObjectByKey(keypair); if (orig != null) { int index = this.IndexOf(orig); this.SetItem(index, item); return(true); } return(false); }
public DrMedicineTmp GetObjectByKey(long k_DrMedTmpID, LV.Core.DAL.Base.IRepository repository) { if (this.Contains(GetKey(k_DrMedTmpID)) == false) { DrMedicineTmp ob = repository.GetQuery <DrMedicineTmp>().FirstOrDefault(o => o.DrMedTmpID == k_DrMedTmpID); if (ob != null) { this.Add(ob); } return(ob); } DrMedicineTmp obj = this[GetKey(k_DrMedTmpID)]; return((DrMedicineTmp)obj); }
public bool DeleteObject(DrMedicineTmp item, LV.Core.DAL.Base.IRepository repository) { repository.Update(item); return(true); }
public bool AddObject(DrMedicineTmp item, LV.Core.DAL.Base.IRepository repository) { repository.Add(item); return(true); }
protected override KeyValuePair <string, long> GetKeyForItem(DrMedicineTmp item) { return(item.Key); }