updated plugin W3 Total Cache version 2.5.0

This commit is contained in:
2023-10-22 22:21:26 +00:00
committed by Gitium
parent 2f6b5b6047
commit 9e3fa792d7
255 changed files with 10113 additions and 23010 deletions

View File

@ -36,6 +36,24 @@ class ObjectCache_WpObjectCache {
return $cache->get( $id, $group, $force, $found );
}
/**
* Retrieves multiple values from the cache in one call.
*
* @since 2.2.8
*
* @param array $ids Array of keys under which the cache contents are stored.
* @param string $group Optional. Where the cache contents are grouped. Default 'default'.
* @param bool $force Optional. Whether to force an update of the local cache
* from the persistent cache. Default false.
*
* @return array Array of return values, grouped by key. Each value is either
* the cache contents on success, or false on failure.
*/
public function get_multiple( $ids, $group = 'default', $force = false ) {
$cache = $this->_get_engine( $group );
return $cache->get_multiple( $ids, $group, $force );
}
/**
* Set to the cache
*
@ -50,6 +68,23 @@ class ObjectCache_WpObjectCache {
return $cache->set( $id, $data, $group, $expire );
}
/**
* Sets multiple values to the cache in one call.
*
* @since 2.2.8
*
* @param array $data Array of key and value to be set.
* @param string $group Optional. Where the cache contents are grouped. Default empty.
* @param int $expire Optional. When to expire the cache contents, in seconds.
* Default 0 (no expiration).
*
* @return bool[] Array of return values, grouped by key. Each value is always true.
*/
public function set_multiple( $data, $group = 'default', $expire = 0 ) {
$cache = $this->_get_engine( $group );
return $cache->set_multiple( $data, $group, $expire );
}
/**
* Delete from the cache
*
@ -63,6 +98,22 @@ class ObjectCache_WpObjectCache {
return $cache->delete( $id, $group, $force );
}
/**
* Deletes multiple values from the cache in one call.
*
* @since 2.2.8
*
* @param array $keys Array of keys to be deleted.
* @param string $group Optional. Where the cache contents are grouped. Default empty.
*
* @return bool[] Array of return values, grouped by key. Each value is either
* true on success, or false if the contents were not deleted.
*/
public function delete_multiple( $keys, $group = 'default' ) {
$cache = $this->_get_engine( $group );
return $cache->delete_multiple( $keys, $group );
}
/**
* Add to the cache
*
@ -77,6 +128,24 @@ class ObjectCache_WpObjectCache {
return $cache->add( $id, $data, $group, $expire );
}
/**
* Adds multiple values to the cache in one call.
*
* @since 2.2.8
*
* @param array $data Array of keys and values to be added.
* @param string $group Optional. Where the cache contents are grouped. Default empty.
* @param int $expire Optional. When to expire the cache contents, in seconds.
* Default 0 (no expiration).
*
* @return bool[] Array of return values, grouped by key. Each value is either
* true on success, or false if cache key and group already exist.
*/
public function add_multiple( array $data, $group = '', $expire = 0 ) {
$cache = $this->_get_engine( $group );
return $cache->add_multiple( $data, $group, $expire );
}
/**
* Replace in the cache
*