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