private void lowerCase(StringInItem set, IndexFacts.Session indexFacts) {
        if ( ! syntheticLowerCaseCheck(set.getIndexName(), indexFacts, true)) {
            return;
        }

        // set.getTokens() uses Set.copyOf(), thus modification to original set is not reflected in
        // set being iterated over.
        var originalTokens = set.getTokens();
        for (String originalToken : originalTokens) {
            String token = toLowerCase(originalToken);
            if (!originalToken.equals(token)) {
                set.removeToken(originalToken);
                set.addToken(token);
            }
        }
    }
Traverse a query tree and lowercase terms based on decision made in subclasses.

@author Steinar Knutsen
container-search/src/main/java/com/yahoo/search/querytransform/LowercasingSearcher.java