mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 02:28:44 +02:00
N°6934 - Symfony 6.4 - upgrade Symfony bundles to 6.4 (#580)
* Update Symfony lib to version ~6.4.0 * Update code missing return type * Add an iTop general configuration entry to store application secret (Symfony mandatory parameter) * Use dependency injection in ExceptionListener & UserProvider classes
This commit is contained in:
@@ -23,26 +23,28 @@ use Symfony\Component\DependencyInjection\Definition;
|
||||
*/
|
||||
class ServiceReferenceGraphNode
|
||||
{
|
||||
private $id;
|
||||
private $inEdges = [];
|
||||
private $outEdges = [];
|
||||
private $value;
|
||||
private string $id;
|
||||
private array $inEdges = [];
|
||||
private array $outEdges = [];
|
||||
private mixed $value;
|
||||
|
||||
/**
|
||||
* @param string $id The node identifier
|
||||
* @param mixed $value The node value
|
||||
*/
|
||||
public function __construct(string $id, $value)
|
||||
public function __construct(string $id, mixed $value)
|
||||
{
|
||||
$this->id = $id;
|
||||
$this->value = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return void
|
||||
*/
|
||||
public function addInEdge(ServiceReferenceGraphEdge $edge)
|
||||
{
|
||||
$this->inEdges[] = $edge;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return void
|
||||
*/
|
||||
public function addOutEdge(ServiceReferenceGraphEdge $edge)
|
||||
{
|
||||
$this->outEdges[] = $edge;
|
||||
@@ -50,30 +52,24 @@ class ServiceReferenceGraphNode
|
||||
|
||||
/**
|
||||
* Checks if the value of this node is an Alias.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function isAlias()
|
||||
public function isAlias(): bool
|
||||
{
|
||||
return $this->value instanceof Alias;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the value of this node is a Definition.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function isDefinition()
|
||||
public function isDefinition(): bool
|
||||
{
|
||||
return $this->value instanceof Definition;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the identifier.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getId()
|
||||
public function getId(): string
|
||||
{
|
||||
return $this->id;
|
||||
}
|
||||
@@ -83,7 +79,7 @@ class ServiceReferenceGraphNode
|
||||
*
|
||||
* @return ServiceReferenceGraphEdge[]
|
||||
*/
|
||||
public function getInEdges()
|
||||
public function getInEdges(): array
|
||||
{
|
||||
return $this->inEdges;
|
||||
}
|
||||
@@ -93,23 +89,23 @@ class ServiceReferenceGraphNode
|
||||
*
|
||||
* @return ServiceReferenceGraphEdge[]
|
||||
*/
|
||||
public function getOutEdges()
|
||||
public function getOutEdges(): array
|
||||
{
|
||||
return $this->outEdges;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the value of this Node.
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function getValue()
|
||||
public function getValue(): mixed
|
||||
{
|
||||
return $this->value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Clears all edges.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function clear()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user