I'm extracting terms from the query calling ExtractTerms()
on the Query object that I get as the result of QueryParser.Parse()
. I get a HashTable, but each item present as:
Key - term:term
Value - term:term
- Why are the key and the value the same? And more why is term value duplicated and separated by colon?
- Do highlighters only insert tags or to do anything else? I want not only to get text fragments but to highlight the source text (it's big enough). I try to get terms and by offsets to insert tags by hand. But I worry if this is the right solution.