mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2025-09-13 21:57:16 +02:00
Refactored relation and node draft
This commit is contained in:
@@ -1,26 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Entity\Attribut;
|
||||
|
||||
use App\Entity\NodeInterface;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
trait NodeAttribut
|
||||
{
|
||||
/**
|
||||
* @var NodeInterface
|
||||
*/
|
||||
protected $node;
|
||||
|
||||
public function setNode(NodeInterface $node): void
|
||||
{
|
||||
$this->node = $node;
|
||||
}
|
||||
|
||||
public function getNode(): NodeInterface
|
||||
{
|
||||
return $this->node;
|
||||
}
|
||||
}
|
@@ -1,15 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Entity\Attribut;
|
||||
|
||||
use App\Entity\NodeInterface;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
interface NodeAttributInterface
|
||||
{
|
||||
public function setNode(NodeInterface $node): void;
|
||||
|
||||
public function getNode(): NodeInterface;
|
||||
}
|
26
application/src/Entity/Attribut/RelationAttribut.php
Normal file
26
application/src/Entity/Attribut/RelationAttribut.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace App\Entity\Attribut;
|
||||
|
||||
use App\Entity\RelationInterface;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
trait RelationAttribut
|
||||
{
|
||||
/**
|
||||
* @var RelationInterface
|
||||
*/
|
||||
protected $relation;
|
||||
|
||||
public function setRelation(RelationInterface $relation): void
|
||||
{
|
||||
$this->relation = $relation;
|
||||
}
|
||||
|
||||
public function getRelation(): RelationInterface
|
||||
{
|
||||
return $this->relation;
|
||||
}
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
namespace App\Entity\Attribut;
|
||||
|
||||
use App\Entity\RelationInterface;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
interface RelationAttributInterface
|
||||
{
|
||||
public function setRelation(RelationInterface $relation): void;
|
||||
|
||||
public function getRelation(): RelationInterface;
|
||||
}
|
Reference in New Issue
Block a user