1 | <?php |
||
16 | class CacheCommand implements Command |
||
17 | { |
||
18 | |||
19 | /** @var \League\CLImate\CLImate */ |
||
20 | private $cli; |
||
21 | |||
22 | /** @var \League\Tactician\CommandBus */ |
||
23 | private $bus; |
||
24 | |||
25 | public function __construct(CLImate $cli, CommandBus $bus) |
||
30 | |||
31 | /** |
||
32 | * Handles `c5 cache:clear` |
||
33 | */ |
||
34 | public function clear(Site $site) |
||
50 | |||
51 | /** |
||
52 | * Get the command definitions this command provides |
||
53 | * |
||
54 | * @param \Buttress\Concrete\Locator\Site|null $site |
||
55 | * @return \League\CLImate\Argument\Manager[] A list containing a manager for each command this instance offers |
||
56 | */ |
||
57 | public function getCommands(Site $site) |
||
76 | |||
77 | /** |
||
78 | * Register command routes |
||
79 | * |
||
80 | * @param \Buttress\Concrete\Route\RouteCollector $collector |
||
81 | * @param \Buttress\Concrete\Locator\Site|null $site |
||
82 | */ |
||
83 | public function registerRoutes(RouteCollector $collector, Site $site = null) |
||
90 | |||
91 | /** |
||
92 | * Check if we should be enabled |
||
93 | * |
||
94 | * @param \Buttress\Concrete\Locator\Site $site |
||
95 | * @return bool |
||
96 | */ |
||
97 | private function enabled(Site $site = null) |
||
101 | } |
||
102 |