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

JaroWinklerDistance returns 0f when s1.length()=s2.length()=0

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 4.0-ALPHA
    • Fix Version/s: None
    • Component/s: modules/spellchecker
    • Labels:
      None
    • Environment:

      JDK1.6.17

    • Lucene Fields:
      New

      Description

      StringDistance sd = new JaroWinklerDistance();
      System.out.println(sd.getDistance("",""));

      console prints 0.

      but when use LevensteinDistance or NGramDistance, that console prints 1.0

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              tom_lt tom liu
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: