I'm using IndexTank with the Java client, but I can't seem to access the results:
SearchResults results = index.search(Query.forString(keywords));
for (Map<String, Object> document : results.results) {
System.out.println("doc id: " + document.get("docid"));
The last line fails with: Type mismatch: cannot convert from Object to String
Does anyone know why I get this error? Thanks.
What you have looks fine. Are you sure you're importing all of the right classes? This works for me: