Lucene - Core
  1. Lucene - Core
  2. LUCENE-3513

Add SimpleFragListBuilder constructor with margin parameter

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.9
    • Fix Version/s: 3.5, 4.0-ALPHA
    • Component/s: modules/highlighter
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      SimpleFragListBuilder would benefit from an additional constructor that takes in margin. Currently, the margin is defined as a constant, so to "implement" a FragListBuilder with a different margin, one has no choice but to copy and paste SimpleFragListBuilder into a new class that must be placed in the org.apache.lucene.search.vectorhighlight package due to accesses of package-protected fields in other classes.

      If this change were made, the precondition check of the constructor's fragCharSize should probably be altered to ensure that it's less than max(1, margin*3) to allow for a margin of 0.

      1. LUCENE-3513.patch
        4 kB
        Koji Sekiguchi
      2. LUCENE-3513.patch
        2 kB
        Kelsey Francis

        Activity

        Kelsey Francis created issue -
        Kelsey Francis made changes -
        Field Original Value New Value
        Attachment LUCENE-3513.patch [ 12498776 ]
        Koji Sekiguchi made changes -
        Attachment LUCENE-3513.patch [ 12499194 ]
        Koji Sekiguchi made changes -
        Assignee Koji Sekiguchi [ koji ]
        Fix Version/s 3.5 [ 12317877 ]
        Fix Version/s 4.0 [ 12314025 ]
        Affects Version/s 2.9 [ 12312682 ]
        Affects Version/s 3.4 [ 12316675 ]
        Koji Sekiguchi made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Uwe Schindler made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Koji Sekiguchi
            Reporter:
            Kelsey Francis
          • Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development