mirror of
https://we.phorge.it/source/arcanist.git
synced 2024-10-24 17:48:50 +02:00
32 lines
693 B
PHP
32 lines
693 B
PHP
|
<?php
|
||
|
|
||
|
abstract class ArcanistFutureLinter extends ArcanistLinter {
|
||
|
|
||
|
private $futures;
|
||
|
|
||
|
abstract function buildFutures(array $paths);
|
||
|
abstract function resolveFuture($path, Future $future);
|
||
|
|
||
|
public function willLintPaths(array $paths) {
|
||
|
$this->futures = $this->buildFutures($paths);
|
||
|
if (is_array($this->futures)) {
|
||
|
foreach ($this->futures as $future) {
|
||
|
$future->isReady();
|
||
|
}
|
||
|
$this->futures = Futures($this->futures);
|
||
|
}
|
||
|
}
|
||
|
|
||
|
public function lintPath($path) {
|
||
|
}
|
||
|
|
||
|
public function didRunLinters() {
|
||
|
if ($this->futures) {
|
||
|
foreach ($this->futures as $path => $future) {
|
||
|
$this->resolveFuture($path, $future);
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
}
|