mirror of
https://github.com/rectorphp/rector.git
synced 2025-02-24 11:44:14 +01:00
add RectorGuess
This commit is contained in:
parent
d610966b81
commit
9364f1b7d1
60
packages/DeprecationExtractor/src/RectorGuess.php
Normal file
60
packages/DeprecationExtractor/src/RectorGuess.php
Normal file
@ -0,0 +1,60 @@
|
||||
<?php declare(strict_types=1);
|
||||
|
||||
namespace Rector\DeprecationExtractor\Rector;
|
||||
|
||||
use PhpParser\Node;
|
||||
|
||||
final class RectorGuess
|
||||
{
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
private $guessedRectorClass;
|
||||
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
private $certainity;
|
||||
|
||||
/**
|
||||
* @var Node
|
||||
*/
|
||||
private $node;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
private $message;
|
||||
|
||||
public function __construct(
|
||||
string $guessedRectorClass,
|
||||
float $certainity,
|
||||
Node $node,
|
||||
string $message = ''
|
||||
) {
|
||||
$this->guessedRectorClass = $guessedRectorClass;
|
||||
$this->certainity = $certainity;
|
||||
$this->node = $node;
|
||||
$this->message = $message;
|
||||
}
|
||||
|
||||
public function getGuessedRectorClass(): string
|
||||
{
|
||||
return $this->guessedRectorClass;
|
||||
}
|
||||
|
||||
public function getCertainity(): float
|
||||
{
|
||||
return $this->certainity;
|
||||
}
|
||||
|
||||
public function getNode(): Node
|
||||
{
|
||||
return $this->node;
|
||||
}
|
||||
|
||||
public function getMessage(): string
|
||||
{
|
||||
return $this->message;
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user