@@ -4342,7 +4342,7 @@ public static function macroCall($method, $parameters)
43424342 */
43434343 public static function lock($name, $seconds = 0, $owner = null)
43444344 {
4345- /** @var \Illuminate\Cache\FileStore $instance */
4345+ /** @var \Illuminate\Cache\DatabaseStore $instance */
43464346 return $instance->lock($name, $seconds, $owner);
43474347 }
43484348 /**
@@ -4355,65 +4355,54 @@ public static function lock($name, $seconds = 0, $owner = null)
43554355 */
43564356 public static function restoreLock($name, $owner)
43574357 {
4358- /** @var \Illuminate\Cache\FileStore $instance */
4358+ /** @var \Illuminate\Cache\DatabaseStore $instance */
43594359 return $instance->restoreLock($name, $owner);
43604360 }
43614361 /**
4362- * Remove all items from the cache.
4363- *
4364- * @return bool
4365- * @static
4366- */
4367- public static function flush()
4368- {
4369- /** @var \Illuminate\Cache\FileStore $instance */
4370- return $instance->flush();
4371- }
4372- /**
4373- * Get the full path for the given cache key.
4362+ * Remove an item from the cache if it is expired.
43744363 *
43754364 * @param string $key
4376- * @return string
4365+ * @return bool
43774366 * @static
43784367 */
4379- public static function path ($key)
4368+ public static function forgetIfExpired ($key)
43804369 {
4381- /** @var \Illuminate\Cache\FileStore $instance */
4382- return $instance->path ($key);
4370+ /** @var \Illuminate\Cache\DatabaseStore $instance */
4371+ return $instance->forgetIfExpired ($key);
43834372 }
43844373 /**
4385- * Get the Filesystem instance .
4374+ * Remove all items from the cache .
43864375 *
4387- * @return \Illuminate\Filesystem\Filesystem
4376+ * @return bool
43884377 * @static
43894378 */
4390- public static function getFilesystem ()
4379+ public static function flush ()
43914380 {
4392- /** @var \Illuminate\Cache\FileStore $instance */
4393- return $instance->getFilesystem ();
4381+ /** @var \Illuminate\Cache\DatabaseStore $instance */
4382+ return $instance->flush ();
43944383 }
43954384 /**
4396- * Get the working directory of the cache .
4385+ * Get the underlying database connection .
43974386 *
4398- * @return string
4387+ * @return \Illuminate\Database\MySqlConnection
43994388 * @static
44004389 */
4401- public static function getDirectory ()
4390+ public static function getConnection ()
44024391 {
4403- /** @var \Illuminate\Cache\FileStore $instance */
4404- return $instance->getDirectory ();
4392+ /** @var \Illuminate\Cache\DatabaseStore $instance */
4393+ return $instance->getConnection ();
44054394 }
44064395 /**
4407- * Set the cache directory where locks should be stored .
4396+ * Specify the name of the connection that should be used to manage locks .
44084397 *
4409- * @param string|null $lockDirectory
4410- * @return \Illuminate\Cache\FileStore
4398+ * @param \Illuminate\Database\ConnectionInterface $connection
4399+ * @return \Illuminate\Cache\DatabaseStore
44114400 * @static
44124401 */
4413- public static function setLockDirectory($lockDirectory )
4402+ public static function setLockConnection($connection )
44144403 {
4415- /** @var \Illuminate\Cache\FileStore $instance */
4416- return $instance->setLockDirectory($lockDirectory );
4404+ /** @var \Illuminate\Cache\DatabaseStore $instance */
4405+ return $instance->setLockConnection($connection );
44174406 }
44184407 /**
44194408 * Get the cache key prefix.
@@ -4423,7 +4412,7 @@ public static function setLockDirectory($lockDirectory)
44234412 */
44244413 public static function getPrefix()
44254414 {
4426- /** @var \Illuminate\Cache\FileStore $instance */
4415+ /** @var \Illuminate\Cache\DatabaseStore $instance */
44274416 return $instance->getPrefix();
44284417 }
44294418
0 commit comments