private Item instantiateNearItem(String field, String key, Inspector value) {
        assertHasOperator(key, NEAR);

        NearItem near = new NearItem();
        near.setIndexName(field);

        HashMap<Integer, Inspector> children = childMap(value);

        for (Inspector word :  children.values()){
            near.addItem(new WordItem(word.asString(), field));
        }

        Integer distance = getIntegerAnnotation(DISTANCE, getAnnotationMap(value), null);

        if (distance != null) {
            near.setDistance(distance);
        }
        return near;
    }
Translates a list of grouping requests on JSON form to a list in the grouping language form
container-search/src/main/java/com/yahoo/search/query/SelectParser.java