public RankProfile.InputType rankProfileInput(String rankFeature, String rankProfile) {
            if (schemas.isEmpty()) return null; // no matching schemas - validated elsewhere
            List<RankProfile> profiles = profilesNamed(rankProfile);
            if (profiles.isEmpty())
                throw new IllegalArgumentException("No profile named '" + rankProfile + "' exists in schemas [" +
                                                   schemas.stream().map(Schema::name).collect(Collectors.joining(", ")) + "]");
            RankProfile.InputType foundType = null;
            RankProfile declaringProfile = null;
            for (RankProfile profile : profiles) {
                RankProfile.InputType newlyFoundType = profile.inputs().get(rankFeature);
                if (newlyFoundType == null) continue;
                if (foundType != null && ! newlyFoundType.equals(foundType))
                    throw new IllegalArgumentException("Conflicting input type declarations for '" + rankFeature + "': " +
                                                       "Declared as " + foundType + " in " + declaringProfile +
                                                       ", and as " + newlyFoundType + " in " + profile);
                foundType = newlyFoundType;
                declaringProfile = profile;
            }
            return foundType;
        }
Returns the type of the given rank feature name in the given profile,
if it can be uniquely determined.

@param rankFeature the rank feature name, a string on the form "query(name)"
@param rankProfile the name of the rank profile in which to locate the input declaration
@return the type of the declared input, or null if it is not declared or the rank profile is not found
@throws IllegalArgumentException if the given rank profile does not exist in any schema, or the
        feature is declared in this rank profile in multiple schemas
        of this session with conflicting types
container-search/src/main/java/com/yahoo/search/schema/SchemaInfo.java