Document doc = searcher.doc(hits[0].doc);
if (doc.getField(QueryBuilder.TAGS) != null) {
byte[] rawTags = doc.getField(QueryBuilder.TAGS).binaryValue().bytes;
Definitions tags = Definitions.deserialize(rawTags);
String symbol = ((TermQuery) query).getTerm().text();
if (tags.occurrences(symbol) == 1) {
uniqueDefinition = true;
}
}
}
// @TODO fix me. I should try to figure out where the exact hit is