eZ\Publish\Core\SignalSlot\TrashService::trash PHP Method

trash() public method

Content is left untouched.
public trash ( eZ\Publish\API\Repository\Values\Content\Location $location ) : null | eZ\Publish\API\Repository\Values\Content\TrashItem
$location eZ\Publish\API\Repository\Values\Content\Location
return null | eZ\Publish\API\Repository\Values\Content\TrashItem null if location was deleted, otherwise TrashItem
    public function trash(Location $location)
    {
        $returnValue = $this->service->trash($location);
        $this->signalDispatcher->emit(new TrashSignal(array('locationId' => $location->id, 'parentLocationId' => $location->parentLocationId, 'contentId' => $location->contentId, 'contentTrashed' => $returnValue instanceof TrashItem)));
        return $returnValue;
    }