/** * @param Deputy $deputy * @return HasDeputiesInterface */ public function removeDeputy(Deputy $deputy) { if (true === $this->hasDeputy($deputy)) { $this->deputies->removeElement($deputy); } return $this; }
/** * @return $this */ public function removeParcelResponse(ParcelResponse $parcelResponse) { if ($this->parcelResponses->contains($parcelResponse)) { $this->parcelResponses->removeElement($parcelResponse); } return $this; }
/** * @param \Opg\Core\Model\Entity\LineItem\LineItem $closingBalance * @return HasClosingBalances */ public function removeClosingBalance(LineItem $closingBalance) { if ($this->closingBalanceExists($closingBalance)) { $this->closingBalances->removeElement($closingBalance); } return $this; }
/** * @param LineItem $asset * @return HasAssetLog */ public function removeAsset(LineItem $asset) { if ($this->assetExists($asset)) { $this->assets->removeElement($asset); } return $this; }
/** * @inheritdoc */ public function remove(User $user) { if (!$this->collection->containsKey((string) $user->getId())) { throw new UserNotFoundException(); } return $this->collection->removeElement($user); }
/** * @param CourtFund $fund * @return HasCourtFundsInterface */ public function removeCourtFund(CourtFund $fund) { if ($this->hasCourtFund($fund)) { $this->courtFunds->removeElement($fund); } return $this; }
public function removePost(Post $post) { if ($this->posts->contains($post)) { $this->posts->removeElement($post); } return $this; }
/** * @param Fees $fee * @return HasFeesInterface */ public function removeFee(Fees $fee) { if (true === $this->hasFee($fee)) { $this->fees->removeElement($fee); } return $this; }
public function removePost(Post $post) { if (!$this->hasPost($post)) { throw new DomainException('Post is not exists'); } $this->posts->removeElement($post); }
/** * @param UndoableCommandInterface $cmd */ public function undo(UndoableCommandInterface $cmd) { if ($this->history->removeElement($cmd) === false) { throw new CommandDispatcherException('Command is not executed, nothing to undo.'); } $cmd->undo(); }
/** * @param FolderUser $user * @return $this */ public function removeUser(FolderUser $user) { if ($this->hasUser($user)) { $this->Users->removeElement($user); } return $this; }
/** * @param Category $category * @param bool $stopPropagation * @return $this */ public function removeCategory(Category $category, $stopPropagation = false) { $this->categories->removeElement($category); if (!$stopPropagation) { $category->removeDocument($this, true); } return $this; }
public function removePermission($permission) { if (null === $permission || false === is_string($permission)) { trigger_error("removePermission expected Argument to be a string not null", E_USER_ERROR); } $this->permissions->removeElement($permission); return $this; }
/** * Remove a lesson from the section. * * @param Section $section * * @return $this */ public function removeSection(Section $section) { if ($this->sections->contains($section)) { $this->sections->removeElement($section); $section->setLesson(null); } return $this; }
/** * @param User $user * @return bool */ public function removeUser(User $user) { if ($this->hasUser($user)) { $this->Users->removeElement($user); return true; } return false; }
/** * @param CaseItem $caseItem * @return HasCasesInterface */ public function removeCase(CaseItem $caseItem) { $this->initCases(); if (true == $this->cases->contains($caseItem)) { $this->cases->removeElement($caseItem); } return $this; }
/** * @param UserInterface $user * * @return RoleInterface */ public function removeUser(UserInterface $user) { $this->users->removeElement($user); if ($user->hasRole($this) === true) { $user->removeRole($this); } return $this; }
/** * @param AttorneyAbstract $attorney * @return HasAttorneys */ public function removeAttorney(AttorneyAbstract $attorney) { $this->initAttorneys(); if ($this->attorneyExists($attorney)) { $this->attorneys->removeElement($attorney); } return $this; }
/** * {@inheritdoc} */ public function removeWidget(AttributeWidget $widget) { if ($this->hasWidget($widget)) { $this->widgets->removeElement($widget); $widget->getArchetype()->removeAttribute($widget->getAttribute()); $widget->setArchetype(null); } return $this; }
/** * Remove a workflow instance * * @param WorkflowInstanceEntity $workflowInstance Instance entity to remove * * @return self */ public function removeWorkflowInstance(WorkflowInstanceEntity $workflowInstance) { // Check if workflow instances is initialized if (null === $this->workflowInstances) { $this->workflowInstances = new ArrayCollection(); } $this->workflowInstances->removeElement($workflowInstance); return $this; }
/** * {@inheritdoc} */ public function removeProduct(Product $product) { if ($this->hasProduct($product)) { $this->products->removeElement($product); $product->setStore(null); } }
public function removeMedia(Media $media) { if ($this->medias->contains($media)) { $this->medias->removeElement($media); } return $this; }
function removeComments(Comment $comments) { if ($this->comments->contains($comments)) { $this->comments->removeElement($comments); } return $this; }
/** * Remove game * * @param EGGame $game * @return EGGame */ public function removeGame(EGGame $game) { if ($this->games->contains($game)) { $this->games->removeElement($game); } return $this; }
/** * @param EmailFolder $folder * * @return $this */ public function removeSubFolder(EmailFolder $folder) { if ($this->subFolders->contains($folder)) { $this->subFolders->removeElement($folder); } return $this; }
/** * {@inheritDoc} */ public function removeAlias(DocumentInterface $document) { if ($this->aliases->contains($document)) { $this->aliases->removeElement($document); } return $this; }
/** * Removes a given variability option * * @param OptionInterface $variabilityOption * * @return $this */ public function removeVariabilityOption(OptionInterface $variabilityOption) { if ($this->hasVariabilityOption($variabilityOption)) { $this->variabilityOptions->removeElement($variabilityOption); } return $this; }
public function removeObject($class, $removeAttrs = []) { foreach ($removeAttrs as $attr) { $this->attributes[$attr]->set(null); } $this->objects->removeElement($this->getObject($class)); }
/** * @param FlatModel $flat */ public function removeExcludedFlat(FlatModel $flat) { if (!$this->excludedFlats->contains($flat)) { return; } $this->excludedFlats->removeElement($flat); }
/** * @param Blog $blog * * @return Event */ public function removeBlog(Blog $blog) { if ($this->blogs->contains($blog)) { $this->blogs->removeElement($blog); } return $this; }