/**
  * {@inheritdoc}
  */
 public function removeProduct(ProductInterface $product)
 {
     $this->products->removeElement($product);
     return $this;
 }
Пример #2
0
 /**
  * {@inheritdoc}
  */
 public function clearAssociatedProducts()
 {
     $this->associatedProducts->clear();
 }
Пример #3
0
 public function hasChildren()
 {
     return !$this->children->isEmpty();
 }
Пример #4
0
 /**
  * {@inheritdoc}
  */
 public function removeAssociatedProduct(ProductInterface $product)
 {
     if ($this->hasAssociatedProduct($product)) {
         $this->associatedProducts->removeElement($product);
     }
 }