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