private void dereferenceCompoundedVariants(QueryProfile profile,String prefix) {
        // A variant of a.b is represented as the value a pointing to an anonymous profile a
        // having the variants
        for (Map.Entry<String,Object> entry : profile.declaredContent().entrySet()) {
            if ( ! (entry.getValue() instanceof QueryProfile)) continue;
            QueryProfile subProfile = (QueryProfile)entry.getValue();
            // Export if defined implicitly in this, or if this contains overrides
            if (!subProfile.isExplicit() || subProfile instanceof OverridableQueryProfile) {
                String entryPrefix = prefix + entry.getKey() + ".";
                dereferenceCompoundedVariants(subProfile.getVariants(), entryPrefix);
                dereferenceCompoundedVariants(subProfile, entryPrefix);
            }
        }

        if (profile.getVariants() == null) return;
        // We need to do the same dereferencing to overridables pointed to by variants of this
        for (Map.Entry<String,QueryProfileVariants.FieldValues> fieldValueEntry : profile.getVariants().getFieldValues().entrySet()) {
            for (QueryProfileVariants.FieldValue fieldValue : fieldValueEntry.getValue().asList()) {
                if ( ! (fieldValue.getValue() instanceof QueryProfile)) continue;
                QueryProfile subProfile = (QueryProfile)fieldValue.getValue();
                // Export if defined implicitly in this, or if this contains overrides
                if (!subProfile.isExplicit() || subProfile instanceof OverridableQueryProfile) {
                    String entryPrefix = prefix + fieldValueEntry.getKey() + ".";
                    dereferenceCompoundedVariants(subProfile.getVariants(), entryPrefix);
                    dereferenceCompoundedVariants(subProfile, entryPrefix);
                }
            }
        }
    }
Represents a set of query profile variants (more or less) as they were declared -
a helper to produce config, which is also using the "declared" representation

@author bratseth
config-model/src/main/java/com/yahoo/vespa/model/container/search/DeclaredQueryProfileVariants.java