Cache_Command
Cache management commands for Better Search.
Namespace: WebberZone\Better_Search\Pro\CLI
Since: 4.3.0
Source: includes/pro/cli/class-cache-command.php line 24
Extends: Base_Command
Methods
clear()
Clear Better Search cache.
OPTIONS
[–network] : Clear cache for all sites in the network.
[–force] : Force cache clear without confirmation.
[–dry-run] : Show how many entries would be cleared without making changes.
[–verbose] : Show detailed output.
EXAMPLES
wp bsearch cache clear
wp bsearch cache clear --network
wp bsearch cache clear --force
wp bsearch cache clear --dry-run
Line: 53
public function clear( array $args, array $assoc_args ): void;
| Type | Name | Description |
|---|---|---|
array |
$args |
Command arguments. |
array |
$assoc_args |
Command associative arguments. |
Returns: void
warm()
Warm cache by pre-generating search results.
OPTIONS
[–limit=
[–dry-run] : Show what would be warmed without making changes.
[–force] : Force cache warming even if cache exists.
[–verbose] : Show which queries were skipped (no results or already cached).
EXAMPLES
wp bsearch cache warm
wp bsearch cache warm --limit=100
wp bsearch cache warm --dry-run
Line: 116
public function warm( array $args, array $assoc_args ): void;
| Type | Name | Description |
|---|---|---|
array |
$args |
Command arguments. |
array |
$assoc_args |
Command associative arguments. |
Returns: void
status()
Show cache status.
OPTIONS
[–format=
[–url=
[–network] : Show cache status for all sites in the network.
[–blog-id=
EXAMPLES
wp bsearch cache status
wp bsearch cache status --format=json
wp bsearch cache status --network
wp bsearch cache status --blog-id=2
Line: 243
public function status( array $args, array $assoc_args ): void;
| Type | Name | Description |
|---|---|---|
array |
$args |
Command arguments. |
array |
$assoc_args |
Command associative arguments. |
Returns: void