SuggestLivewireMethodNameSolution.php
959 字节
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<?php
namespace Facade\Ignition\Solutions;
use Facade\IgnitionContracts\Solution;
class SuggestLivewireMethodNameSolution implements Solution
{
/** @var string */
private $methodName;
/** @var string */
private $componentClass;
/** @var string|null */
private $suggested;
public function __construct($methodName = null, $componentClass = null, $suggested = null)
{
$this->methodName = $methodName;
$this->componentClass = $componentClass;
$this->suggested = $suggested;
}
public function getSolutionTitle(): string
{
return "Possible typo `{$this->componentClass}::{$this->methodName}()`";
}
public function getDocumentationLinks(): array
{
return [];
}
public function getSolutionDescription(): string
{
return "Did you mean `{$this->suggested}()`?";
}
public function isRunnable(): bool
{
return false;
}
}