@Override
    public JPAUpdateClause update(EntityPath<?> path) {
        if (templates != null) {
            return new JPAUpdateClause(entityManager.get(), path, templates);
        } else {
            return new JPAUpdateClause(entityManager.get(), path);
        }
    }
Factory class for query and DML clause creation

@author tiwe
querydsl-jpa/src/main/java/com/querydsl/jpa/impl/JPAQueryFactory.java