-
-
Notifications
You must be signed in to change notification settings - Fork 0
HasCacheOption
github-actions edited this page Apr 23, 2026
·
1 revision
Provides the standard cache option used by cache-writing commands.
- Full name:
\FastForward\DevTools\Console\Input\HasCacheOption
Adds the standard cache control option to the current command.
protected addCacheOption(string $description): staticParameters:
| Parameter | Type | Description |
|---|---|---|
$description |
string | the cache option description |
Adds the standard cache directory option to the current command.
protected addCacheDirOption(string $description, string $default): staticParameters:
| Parameter | Type | Description |
|---|---|---|
$description |
string | the cache directory option description |
$default |
string | the command-specific default cache directory |
Resolves whether cache writes SHOULD be enabled for the current invocation.
protected isCacheEnabled(\Symfony\Component\Console\Input\InputInterface $input, bool $default = true): boolParameters:
| Parameter | Type | Description |
|---|---|---|
$input |
\Symfony\Component\Console\Input\InputInterface | the current command input |
$default |
bool | the command-specific default cache behavior when the option is omitted |
Returns the explicit cache flag that SHOULD be forwarded to nested commands.
protected resolveCacheArgument(\Symfony\Component\Console\Input\InputInterface $input): ?stringParameters:
| Parameter | Type | Description |
|---|---|---|
$input |
\Symfony\Component\Console\Input\InputInterface | the current command input |
Resolves a nested cache directory for a child command.
protected resolveCacheDirArgument(\Symfony\Component\Console\Input\InputInterface $input, string $path = ''): ?stringParameters:
| Parameter | Type | Description |
|---|---|---|
$input |
\Symfony\Component\Console\Input\InputInterface | the current command input |
$path |
string | the child cache path relative to the current command cache root |