Search in sources :

Example 1 with BsClickLogCQ

use of org.codelibs.fess.es.log.cbean.cq.bs.BsClickLogCQ in project fess by codelibs.

the class BsClickLogCA method filter.

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

Aggregations

ClickLogCA (org.codelibs.fess.es.log.cbean.ca.ClickLogCA)1 ClickLogCQ (org.codelibs.fess.es.log.cbean.cq.ClickLogCQ)1 BsClickLogCQ (org.codelibs.fess.es.log.cbean.cq.bs.BsClickLogCQ)1 FilterAggregationBuilder (org.elasticsearch.search.aggregations.bucket.filter.FilterAggregationBuilder)1