Get a value from the cache.

@param  string $id

@return mixed
357266
public static function getFromCache($id)
    {
        $arrayCache = Configuration::getArrayCache();
        if ($arrayCache->contains($id)) {
            return $arrayCache->fetch($id);
        }

        $cacheDriver = Configuration::getCacheDriver();
        if ($cacheDriver !== null) {
            $cacheResult = $cacheDriver->fetch($id);
            if ($cacheResult !== false) {
                $arrayCache->save($id, $cacheResult);
                return $cacheResult;
            }
        }

        return null;
    }
465349
public function getFromCache($ID)
    {
        /* Compute the path */
        $Database = $this->CacheFolder . "/" . $this->CacheDB;

        /* Lookup for the picture in the cache */
        $CacheInfo = $this->isInCache($ID, true, true);

        /* Not in the cache */
        if (!$CacheInfo) {
            return null;
        }

        /* Get the database extended information */
        $DBPos = $CacheInfo["DBPos"];
        $PicSize = $CacheInfo["PicSize"];

        /* Extract the picture from the solid cache file */
        $Handle = @fopen($Database, "r");
        fseek($Handle, $DBPos);
        $Picture = fread($Handle, $PicSize);
        fclose($Handle);

        /* Return back the raw picture data */
        return $Picture;
    }
245251
public function findCacheById(int $id)
    {

        // Check if already in addToCache
        if ($this->isCachedById($id)) {
            return $this->cacheById[$id];
        }

        return null;
    }
1370371
public function find($id)
    {
        if ($this->refresh) {
            $this->forget($id);
        }
        return $this->cache->remember($this->keyPrefix . $id . implode('-', $this->with), $this->minutesToCache,
            function () use ($id) {
                return $this->decorated->find($id);
            });
    }
662687
public function offsetGet($id)
    {
        if (!isset($this->registered[$id])){
            return null;
        }
        if (isset($this->instances[$id])){
            return $this->instances[$id];
        }
        // create new object via factory
        $factory = $this->factories[$id];
        if (!$factory || !is_callable($factory) || !method_exists($factory, '__invoke')){
            return null;
        }
        // get current slot
        $slot = $this->slots[$id] ?? new Slot($id);
        // callback factory to get new instance
        $newInstance = $this->callbackFactory($id, $slot, $factory);
        // replace instance
        $this->replaceInstance($id, $slot, $newInstance);
        return $newInstance;
    }
1059425
public function findOrFail($id)
    {
        if ($this->refresh) {
            $this->forget($id);
        }
        return $this->cache->remember($this->keyPrefix . $id, $this->minutesToCache, function () use ($id) {
            return $this->decorated->findOrFail($id);
        });
    }
1113806
public function getById($id)
    {
        return isset($this->_data[$id]) ? $this->_data[$id] : null;
    }
945124
public function fetch($id)
    {
        $item = $this->cache->getItem((string) $id);

        if (!$item->isHit()) {
            return false;
        }

        return $item->get();
    }
274990
public function get($id) {
        return $this->request("GET", self::URL_ORDERS . $id . "/", $api_key = $this->culqi->api_key);
    }
1157813
public function fetch( $id ) {

		if ( $this->contains( $id ) ) {
			$this->cacheHits++;
			return $this->cache->getItem( $id );
		}

		$this->cacheMisses++;
		return false;
	}
1130642
public static function getByID($id)
    {
        $record = static::getRecordByField(static::$primaryKey ? static::$primaryKey : 'ID', $id, true);

        return static::instantiateRecord($record);
    }
638064
public function remove($id)
    {
        if (true === $result = @unlink($this->getCacheFile($id))) {
            $this->log('debug', sprintf('Cache data removed for id `%s`.', $id));
        }

        return $result;
    }
807478
protected static function getCache($id)
    {
        $type = static::getType();

        $id = (string)$id;

        static::initializeCache($type);

        $collection = self::$cache->{$type};

        if (!property_exists($collection, $id)) {
            return null;
        }

        $resource = $collection->{$id};

        return (clone $resource);
    }
142015
public function get($id) {
		$result = $this->getBackend()->get($id);
		
		if ($result !== null) {
			return json_decode($result);
		}
	}
768240
public function get($id) {
		// Format id
		$id = $this->_format($id);
		// Verify existence
		if(!$this->has($id)) {
			throw new NotFoundException("'$id' value does not exist");
		}
		// Get value
		return $this->values[$id]->getValue();
	}
163666
public function getCacheId($id)
    {
        if(is_array($id))
        {
            $tmp = "";
            foreach ($id as $key => $value)
            {
                $tmp .= $key . "_" . $value;
            }
            $id = $tmp;
        }
        return $this->addCacheIndex($this->table_name . '_' . $id);
    }
879875
public function get($id) {
		if (!$this->securities->has($id)) {
			$this->securities->set($id, new Set());
		}
		return $this->securities->get($id);
	}