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