package com.arms.egovframework.javaservice.esframework.esquery.must;

import org.opensearch.index.query.AbstractQueryBuilder;
import org.opensearch.index.query.QueryBuilders;
import org.opensearch.index.query.TermQueryBuilder;

public class TermQueryMust extends Must<TermQueryBuilder> {

	private TermQueryBuilder termQueryBuilder;

	public <T> TermQueryMust(String name, T value){
		if(name!=null&&value!=null){
			this.termQueryBuilder = QueryBuilders.termQuery(name, value);
		}
	}

	@Override
	public AbstractQueryBuilder<TermQueryBuilder> abstractQueryBuilder() {
		return termQueryBuilder;
	}
}
