src/EntityQueryBuilder.php
public function delete($delete = null, $alias = null)
    {
        if ($delete === null) {
            $delete = $this->getEntityClassName();

            if ($alias === null) {
                $alias = $this->getEntityAlias();
            }
        }

        parent::delete($delete, $alias);

        return $this;
    }
public function delete($delete = null, $alias = null)
    {
        if ($delete === null) {
            $delete = $this->getEntityClassName();

            if ($alias === null) {
                $alias = $this->getEntityAlias();
            }
        }

        parent::delete($delete, $alias);

        return $this;
    }
Turns the query being built into a bulk delete query that ranges over
a certain entity type.

<code>
$qb = $em->createQueryBuilder()
->delete('User', 'u')
->where('u.id = :user_id')
->setParameter('user_id', 1);
</code>

@param string $delete The class/type whose instances are subject to the deletion.
@param string $alias  The class/type alias used in the constructed query.

@return $this This QueryBuilder instance.
@throws \ReflectionException