Refactored function

This commit is contained in:
Kevin Frantz 2018-10-31 14:38:31 +01:00
parent 4678e14b34
commit 5e6b8bccbe
2 changed files with 4 additions and 9 deletions

View File

@ -18,7 +18,7 @@ use App\Exception\NotProcessedException;
* @ORM\DiscriminatorColumn(name="discr", type="string")
* @ORM\DiscriminatorMap({"and" = "AndOperation"})
*/
abstract class AbstractOperation extends AbstractSource implements OperandInterface
abstract class AbstractOperation extends AbstractSource implements OperationInterface
{
use OperandsAttribut;
@ -47,9 +47,4 @@ abstract class AbstractOperation extends AbstractSource implements OperandInterf
}
throw new NotProcessedException('No result was generated!');
}
public function setOperators(ArrayCollection $operands): void
{
$this->operands = $operands;
}
}

View File

@ -2,7 +2,7 @@
namespace App\Logic\Operation;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
/**
* @author kevinfrantz
@ -12,9 +12,9 @@ interface OperationInterface extends OperandInterface
/**
* Sets the Operators the operation has to deal with.
*
* @param ArrayCollection $operands | OperandInterface[]
* @param Collection $operands | OperandInterface[]
*/
public function setOperators(ArrayCollection $operands): void;
public function setOperands(Collection $operands): void;
/**
* Process the logic.