Search in sources :

Example 1 with BsFileConfigToLabelCQ

use of org.codelibs.fess.es.config.cbean.cq.bs.BsFileConfigToLabelCQ in project fess by codelibs.

the class BsFileConfigToLabelCA method filter.

// ===================================================================================
//                                                                     Aggregation Set
//                                                                           =========
public void filter(String name, EsAbstractConditionQuery.OperatorCall<BsFileConfigToLabelCQ> queryLambda, ConditionOptionCall<FilterAggregationBuilder> opLambda, OperatorCall<BsFileConfigToLabelCA> aggsLambda) {
    FileConfigToLabelCQ cq = new FileConfigToLabelCQ();
    if (queryLambda != null) {
        queryLambda.callback(cq);
    }
    FilterAggregationBuilder builder = regFilterA(name, cq.getQuery());
    if (opLambda != null) {
        opLambda.callback(builder);
    }
    if (aggsLambda != null) {
        FileConfigToLabelCA ca = new FileConfigToLabelCA();
        aggsLambda.callback(ca);
        ca.getAggregationBuilderList().forEach(builder::subAggregation);
    }
}
Also used : FilterAggregationBuilder(org.elasticsearch.search.aggregations.bucket.filter.FilterAggregationBuilder) BsFileConfigToLabelCQ(org.codelibs.fess.es.config.cbean.cq.bs.BsFileConfigToLabelCQ) FileConfigToLabelCQ(org.codelibs.fess.es.config.cbean.cq.FileConfigToLabelCQ) FileConfigToLabelCA(org.codelibs.fess.es.config.cbean.ca.FileConfigToLabelCA)

Aggregations

FileConfigToLabelCA (org.codelibs.fess.es.config.cbean.ca.FileConfigToLabelCA)1 FileConfigToLabelCQ (org.codelibs.fess.es.config.cbean.cq.FileConfigToLabelCQ)1 BsFileConfigToLabelCQ (org.codelibs.fess.es.config.cbean.cq.bs.BsFileConfigToLabelCQ)1 FilterAggregationBuilder (org.elasticsearch.search.aggregations.bucket.filter.FilterAggregationBuilder)1