@Override
    public com.yahoo.search.result.Hit toSearchHit(String summaryClass, com.yahoo.searchlib.aggregation.Hit hit) {
        if (hit instanceof FS4Hit) {
            return convertFs4Hit(summaryClass, (FS4Hit)hit);
        } else if (hit instanceof VdsHit) {
            return convertVdsHit(summaryClass, (VdsHit)hit);
        } else {
            throw new UnsupportedOperationException("Hit type '" + hit.getClass().getName() + "' not supported.");
        }
    }
Creates a new instance of this class.

@param searcher The searcher that owns this converter.
container-search/src/main/java/com/yahoo/search/grouping/vespa/HitConverter.java