All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.wz2cool.elasticsearch.query.builder.MatchPhrasePrefixExtQueryBuilder Maven / Gradle / Ivy

There is a newer version: 0.1.6
Show newest version
package com.github.wz2cool.elasticsearch.query.builder;

import com.github.wz2cool.elasticsearch.lambda.GetStringPropertyFunction;
import com.github.wz2cool.elasticsearch.model.ColumnInfo;
import org.elasticsearch.index.query.MatchPhrasePrefixQueryBuilder;
import org.elasticsearch.index.query.QueryBuilder;

public class MatchPhrasePrefixExtQueryBuilder implements ExtQueryBuilder {

    private final MatchPhrasePrefixQueryBuilder matchPhrasePrefixQueryBuilder;

    public MatchPhrasePrefixExtQueryBuilder(GetStringPropertyFunction getPropertyFunc, String text) {
        final ColumnInfo columnInfo = getColumnInfo(getPropertyFunc);
        this.matchPhrasePrefixQueryBuilder = new MatchPhrasePrefixQueryBuilder(columnInfo.getColumnName(), text);
    }

    @Override
    public QueryBuilder build() {
        return this.matchPhrasePrefixQueryBuilder;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy