class DefaultTermTypeParser implements TermTypeParser {


    @Override
    public void process(Supplier<Term> termSupplier, Function<QueryBuilder, BoolQueryBuilder> function) {
        function.apply(queryBuilder(termSupplier.get()));
    }


    private QueryBuilder queryBuilder(Term term) {
        return TermTypeEnum.of(term.getTermType().trim())
                           .map(e -> createQueryBuilder(e,term))
                           .orElse(QueryBuilders.boolQuery());
    }

    static QueryBuilder createQueryBuilder(TermTypeEnum linkTypeEnum, Term term) {<FILL_FUNCTION_BODY>}
}

        if (term.getColumn().contains(".")) {
            return new NestedQueryBuilder(term.getColumn().split("[.]")[0], linkTypeEnum.process(term), ScoreMode.Max);
        }
        return linkTypeEnum.process(term);
    
<no_super_class>