setSimilarity

Expert: set the Similarity implementation used by this IndexWriter.

NOTE: the similarity must not be null.

Only takes effect when IndexWriter is first created.