Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-2191

rename Tokenizer.reset(Reader) to Tokenizer.setReader(Reader)

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 4.0-BETA, 6.0
    • modules/analysis
    • None
    • New

    Description

      in TokenStream there is a reset() method, but the method in Tokenizer used to set a new Reader is called reset(Reader).

      in my opinion this name overloading creates a lot of confusion, and we see things like reset(Reader) calling reset() even in StandardTokenizer...

      So I think this would be some work to fulfill all the backwards compatibility, but worth it because when you look at the existing reset(Reader) and reset() code in various tokenizers, or the javadocs for Tokenizer, its pretty confusing and inconsistent.

      Attachments

        1. LUCENE-2191.patch
          23 kB
          Robert Muir
        2. LUCENE-2191.patch
          25 kB
          Robert Muir

        Issue Links

          Activity

            People

              Unassigned Unassigned
              rcmuir Robert Muir
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: