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