MultiFieldQueryParser parser = new MultiFieldQueryParser( TestConstants.getTargetLuceneVersion(), new String[] {"title", "description"},
TestConstants.standardAnalyzer, boosts );
Query luceneQuery = parser.parse( "dark" );
FullTextQuery ftQuery = s.createFullTextQuery( luceneQuery, Dvd.class )
.setProjection( FullTextQuery.DOCUMENT_ID, FullTextQuery.EXPLANATION, FullTextQuery.THIS );
@SuppressWarnings("unchecked") List<Object[]> results = ftQuery.list();
assertEquals( 2, results.size() );
for ( Object[] result : results ) {
assertEquals( ftQuery.explain( (Integer) result[0] ).toString(), result[1].toString() );
s.delete( result[2] );
}