Refactored relation and node draft

This commit is contained in:
Kevin Frantz
2018-10-27 14:56:26 +02:00
parent 7734f57c63
commit a95ff0497e
24 changed files with 260 additions and 160 deletions

View File

@@ -0,0 +1,36 @@
<?php
namespace App\Entity\Source\Attribut;
use Doctrine\Common\Collections\Collection;
use App\Entity\Source\GroupSourceInterface;
/**
*
* @author kevinfrantz
*
*/
trait GroupSourcesAttribut
{
/**
*
* @var Collection|GroupSourceInterface[]
*/
protected $groups;
/**
*
* @return Collection|GroupSourceInterface[]
*/
public function getGroupSources():Collection{
return $this->groups;
}
/**
*
* @param Collection|GroupSourceInterface[] $groups
*/
public function setGroupSources(Collection $groups):void{
$this->groups = $groups;
}
}

View File

@@ -0,0 +1,24 @@
<?php
namespace App\Entity\Source\Attribut;
use Doctrine\Common\Collections\Collection;
use App\Entity\Source\GroupSourceInterface;
/**
*
* @author kevinfrantz
*
*/
interface GroupSourcesAttributInterface
{
/**
* @param Collection|GroupSourceInterface[] $groups
*/
public function setGroupSources(Collection $groups):void;
/**
* @return Collection|GroupSourceInterface[]
*/
public function getGroupSources():Collection;
}

View File

@@ -0,0 +1,30 @@
<?php
namespace App\Entity\Source\Attribut;
use Doctrine\Common\Collections\Collection;
/**
*
* @author kevinfrantz
*
*/
trait MembersAttribut
{
/**
*
* @var Collection
*/
protected $members;
public function getMembers(): Collection
{
return $this->members;
}
public function setMembers(Collection $members): void
{
$this->members = $members;
}
}

View File

@@ -9,17 +9,16 @@ use Doctrine\Common\Collections\Collection;
* @author kevinfrantz
*
*/
interface SourcesAttributInterface
interface MembersAttributInterface
{
/**
* @param Collection $members
*/
public function setSources(Collection $sources): void;
public function setMembers(Collection $members): void;
/**
* @return Collection
*/
public function getSources(): Collection;
}
public function getMembers(): Collection;
}

View File

@@ -1,30 +0,0 @@
<?php
namespace App\Entity\Source\Attribut;
use Doctrine\Common\Collections\Collection;
/**
*
* @author kevinfrantz
*
*/
trait SourcesAttribut
{
/**
*
* @var Collection
*/
protected $sources;
public function getSources(): Collection
{
return $this->sources;
}
public function setSources(Collection $sources): void
{
$this->sources = $sources;
}
}