// Get returns the cached attributes for a given id.
554049
func (c *attrCache) Get(id uint64) map[string]interface{} {
	c.mu.RLock()
	defer c.mu.RUnlock()
	attrs := c.attrs[id]
	if attrs == nil {
		return nil
	}

	// Make a copy for safety
	ret := make(map[string]interface{})
	for k, v := range attrs {
		ret[k] = v
	}
	return ret
}
799905
func (environmentApi *EnvironmentApi) Get(id string) (*Environment, error) {
	data, err := environmentApi.configurationService.Get(id, map[string]string{})
	if err != nil {
		return nil, err
	}
	return parseEnvironment(data), nil
}
1360342
func (c *cache) Get(id types.UID) (*PodStatus, error) {
	c.lock.RLock()
	defer c.lock.RUnlock()
	d := c.get(id)
	return d.status, d.err
}
958716
func Get(id string, params *stripe.ThreeDSecureParams) (*stripe.ThreeDSecure, error) {
	return getC().Get(id, params)
}
781946
func (this *MemoryStore) Get(id string) (*Session, error) {
	this.l.RLock()
	defer this.l.RUnlock()
	return this.m[id], nil
}
402619
func (c *Identify2Cache) Get(uid keybase1.UID, gctf GetCheckTimeFunc, gcdf GetCacheDurationFunc, breaksOK bool) (*keybase1.Identify2ResUPK2, error) {
	v, err := c.cache.Get(string(uid))
	if err != nil {
		if err == ramcache.ErrNotFound {
			return nil, nil
		}
		return nil, err
	}
	up, ok := v.(*keybase1.Identify2ResUPK2)
	if !ok {
		return nil, fmt.Errorf("invalid type in cache: %T", v)
	}

	if gctf != nil {
		then := gctf(*up)
		if then == 0 {
			return nil, IdentifyTimeoutError{}
		}
		if up.TrackBreaks != nil && !breaksOK {
			return nil, TrackBrokenError{}
		}

		thenTime := keybase1.FromTime(then)
		timeout := gcdf(*up)
		if time.Since(thenTime) > timeout {
			return nil, IdentifyTimeoutError{}
		}
	}

	return up, nil
}
1334476
func (c *Cache) Get(key string) (resp []byte, ok bool) {
	item, err := memcache.Get(c.Context, cacheKey(key))
	if err != nil {
		if err != memcache.ErrCacheMiss {
			c.Context.Errorf("error getting cached response: %v", err)
		}
		return nil, false
	}
	return item.Value, true
}
516530
func (r *ShardedTTL) Get(tenantID, key string) (interface{}, error) {
	r.Lock()
	defer r.Unlock()

	if !r.isValid(tenantID, key) {
		r.delete(tenantID, key)
		return nil, ErrNotFound
	}

	value, err := r.cache.Get(tenantID, key)
	if err != nil {
		return nil, err
	}

	return value, nil
}
1072878
func (c *Cache) Get(key string) (resp []byte, ok bool) {
	key = keyToFilename(key)
	resp, err := c.d.Read(key)
	if err != nil {
		return []byte{}, false
	}
	return resp, true
}
786260
func Get(id string, params *stripe.SourceObjectParams) (*stripe.Source, error) {
	return getC().Get(id, params)
}
72933
func (c *MemoryCacher) Get(key string) interface{} {
	c.lock.RLock()
	defer c.lock.RUnlock()

	item, ok := c.items[key]
	if !ok {
		return nil
	}
	if item.hasExpired() {
		go c.Delete(key)
		return nil
	}
	return item.val
}
667574
func Get(id string, params *stripe.FileParams) (*stripe.File, error) {
	return getC().Get(id, params)

}
676571
func (s *storeImpl) get(ctx datastore.Context, id string) (*Service, error) {
	svc := &Service{}
	if err := s.ds.Get(ctx, Key(id), svc); err != nil {
		return nil, err
	}
	return svc, nil
}
570254
func (s *CacheOnStorage) Get(key interface{}) (interface{}, error) {
	if item, err := s.cache.Get(key); err != nil {
		return nil, err
	} else if item != nil {
		return item, nil
	}

	item, err := s.storage.Get(key)
	if err != nil {
		return nil, err
	}

	if err := s.cache.Set(item); err != nil {
		// XXX: Maybe make this a non error
		return nil, err
	}
	return item, nil
}
1330282
func (ec *Cache) Get(k string) (item interface{}, ok bool) {
	ec.RLock()
	v, ok := ec.cache[k]
	ec.RUnlock()
	if !ok || v.validUntil.Before(timeNow()) {
		// Can't actually delete this element from the cache here since
		// we can't remove the key from ec.keys without a linear search.
		// It'll get removed during the next cleanup
		return nil, false
	}
	return v.data, ok
}
414686
func (db *DB) Get(id *identity.ID, env envelope.Envelope) error {
	return db.db.View(func(tx *bolt.Tx) error {
		bucket := tx.Bucket([]byte{id.Type()})
		if bucket == nil {
			return errors.New("ID not found")
		}

		b := bucket.Get(id[:])
		if b == nil {
			return errors.New("ID not found")
		}

		return json.Unmarshal(b, env)
	})
}
254228
func (c *rankCache) Get(id uint64) uint64 {
	c.mu.Lock()
	defer c.mu.Unlock()
	return c.entries[id]
}