I am programatically constructing a BoostedQuery and I am creating two TermQuery instances which will be added to BoostedQuery instance:
Query query1 = new TermQuery(new Term("body", "new"));
Query query2 = new TermQuery(new Term("body", "york"));
But I am wondering if I could add some weight to this like I can do in qf field in Solr. Here is an example:
body:new^0.1
body:york^0.1
Any help or a pointer would be appreciated.