def explain(query, doc)
      @dir.synchronize do
        ensure_searcher_open()
        query = do_process_query(query)

        return @searcher.explain(query, doc)
      end
    end
def explain(query, doc)
      @dir.synchronize do
        ensure_searcher_open()
        query = do_process_query(query)

        return @searcher.explain(query, doc)
      end
    end
Returns an Explanation that describes how +doc+ scored against
 +query+.

 This is intended to be used in developing Similarity implementations,
 and, for good performance, should not be displayed with every hit.
 Computing an explanation is as expensive as executing the query over the
 entire index.