eZ\Publish\Core\Repository\TrashService::deleteTrashItem PHP Method

deleteTrashItem() public method

The corresponding content object will be removed
public deleteTrashItem ( eZ\Publish\API\Repository\Values\Content\TrashItem $trashItem )
$trashItem eZ\Publish\API\Repository\Values\Content\TrashItem
    public function deleteTrashItem(APITrashItem $trashItem)
    {
        if ($this->repository->hasAccess('content', 'cleantrash') !== true) {
            throw new UnauthorizedException('content', 'cleantrash');
        }
        if (!is_numeric($trashItem->id)) {
            throw new InvalidArgumentValue('id', $trashItem->id, 'TrashItem');
        }
        $this->repository->beginTransaction();
        try {
            $this->persistenceHandler->trashHandler()->deleteTrashItem($trashItem->id);
            $this->repository->commit();
        } catch (Exception $e) {
            $this->repository->rollback();
            throw $e;
        }
    }