public MLTResult like(List<Integer> docNums) throws IOException {
  Map<String,Map<String,Flt>> fieldTermFreq=new HashMap<String,Map<String,Flt>>();
  Map<String,Map<String,Flt>> mustMatchTerms=new HashMap<String,Map<String,Flt>>();
  Map<String,Map<String,Flt>> mustNOTMatchTerms=new HashMap<String,Map<String,Flt>>();
  for (  Integer docNum : new HashSet<Integer>(docNums)) {
    retrieveTerms(docNum,getFieldNames(),fieldTermFreq);
    retrieveTerms(docNum,getMatchFieldNames(),mustMatchTerms);
    retrieveTerms(docNum,getDifferentFieldNames(),mustNOTMatchTerms);
  }
  MLTResult mltResult=buildQueryFromFieldTermFrequencies(fieldTermFreq,false);
  if (mustMatchTerms.size() > 0) {
    mltResult.setMustMatchQuery(buildMustMatchQuery(mustMatchTerms,true));
  }
  if (mustNOTMatchTerms.size() > 0) {
    mltResult.setMustNOTMatchQuery(buildMustMatchQuery(mustNOTMatchTerms,false));
  }
  return mltResult;
}

public MLTResult like ( List < Integer > docNums ) throws IOException { Map < String , Map < String , Flt > > fieldTermFreq = new HashMap < String , Map < String , Flt > > ( ) ; Map < String , Map < String , Flt > > mustMatchTerms = new HashMap < String , Map < String , Flt > > ( ) ; Map < String , Map < String , Flt > > mustNOTMatchTerms = new HashMap < String , Map < String , Flt > > ( ) ; for ( Integer docNum : new HashSet < Integer > ( docNums ) ) { retrieveTerms ( docNum , getFieldNames ( ) , fieldTermFreq ) ; retrieveTerms ( docNum , getMatchFieldNames ( ) , mustMatchTerms ) ; retrieveTerms ( docNum , getDifferentFieldNames ( ) , mustNOTMatchTerms ) ; } MLTResult mltResult = buildQueryFromFieldTermFrequencies ( fieldTermFreq , false ) ; if ( mustMatchTerms . size ( ) > 0 ) { mltResult . setMustMatchQuery ( buildMustMatchQuery ( mustMatchTerms , true ) ) ; } if ( mustNOTMatchTerms . size ( ) > 0 ) { mltResult . setMustNOTMatchQuery ( buildMustMatchQuery ( mustNOTMatchTerms , false ) ) ; } return mltResult ; }
return a query that will return docs queryfromdocuments the passed lucene document id .
