@Override
    public Model clone() {
        try {
            Model clone = (Model)super.clone();
            if (queryTree != null)
                clone.queryTree = this.queryTree.clone();
            if (sources != null)
                clone.sources = new LinkedHashSet<>(this.sources);
            if (restrict != null)
                clone.restrict = new LinkedHashSet<>(this.restrict);
            return clone;
        }
        catch (CloneNotSupportedException e) {
            throw new RuntimeException("Someone inserted a noncloneable superclass", e);
        }
    }
Sets the query type of this query.
The type is taken into account at the time the query tree is parsed.
Setting this does <i>not</i> cause the query to be reparsed.
container-search/src/main/java/com/yahoo/search/query/Model.java