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