Show / Hide Table of Contents

    Class BaseFragmentsBuilder

    Base IFragmentsBuilder implementation that supports colored pre/post tags and multivalued fields.

    Uses IBoundaryScanner to determine fragments.

    Inheritance
    System.Object
    BaseFragmentsBuilder
    ScoreOrderFragmentsBuilder
    SimpleFragmentsBuilder
    Implements
    IFragmentsBuilder
    Namespace: Lucene.Net.Search.VectorHighlight
    Assembly: Lucene.Net.Highlighter.dll
    Syntax
    public abstract class BaseFragmentsBuilder : object, IFragmentsBuilder

    Constructors

    | Improve this Doc View Source

    BaseFragmentsBuilder()

    Declaration
    protected BaseFragmentsBuilder()
    | Improve this Doc View Source

    BaseFragmentsBuilder(IBoundaryScanner)

    Declaration
    protected BaseFragmentsBuilder(IBoundaryScanner boundaryScanner)
    Parameters
    Type Name Description
    IBoundaryScanner boundaryScanner
    | Improve this Doc View Source

    BaseFragmentsBuilder(String[], String[])

    Declaration
    protected BaseFragmentsBuilder(string[] preTags, string[] postTags)
    Parameters
    Type Name Description
    System.String[] preTags
    System.String[] postTags
    | Improve this Doc View Source

    BaseFragmentsBuilder(String[], String[], IBoundaryScanner)

    Declaration
    protected BaseFragmentsBuilder(string[] preTags, string[] postTags, IBoundaryScanner boundaryScanner)
    Parameters
    Type Name Description
    System.String[] preTags
    System.String[] postTags
    IBoundaryScanner boundaryScanner

    Fields

    | Improve this Doc View Source

    COLORED_POST_TAGS

    Declaration
    public static readonly string[] COLORED_POST_TAGS
    Field Value
    Type Description
    System.String[]
    | Improve this Doc View Source

    COLORED_PRE_TAGS

    Declaration
    public static readonly string[] COLORED_PRE_TAGS
    Field Value
    Type Description
    System.String[]
    | Improve this Doc View Source

    m_postTags

    Declaration
    protected string[] m_postTags
    Field Value
    Type Description
    System.String[]
    | Improve this Doc View Source

    m_preTags

    Declaration
    protected string[] m_preTags
    Field Value
    Type Description
    System.String[]

    Properties

    | Improve this Doc View Source

    IsDiscreteMultiValueHighlighting

    Declaration
    public virtual bool IsDiscreteMultiValueHighlighting { get; set; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    MultiValuedSeparator

    Declaration
    public virtual char MultiValuedSeparator { get; set; }
    Property Value
    Type Description
    System.Char

    Methods

    | Improve this Doc View Source

    CreateFragment(IndexReader, Int32, String, FieldFragList)

    Declaration
    public virtual string CreateFragment(IndexReader reader, int docId, string fieldName, FieldFragList fieldFragList)
    Parameters
    Type Name Description
    IndexReader reader
    System.Int32 docId
    System.String fieldName
    FieldFragList fieldFragList
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    CreateFragment(IndexReader, Int32, String, FieldFragList, String[], String[], IEncoder)

    Declaration
    public virtual string CreateFragment(IndexReader reader, int docId, string fieldName, FieldFragList fieldFragList, string[] preTags, string[] postTags, IEncoder encoder)
    Parameters
    Type Name Description
    IndexReader reader
    System.Int32 docId
    System.String fieldName
    FieldFragList fieldFragList
    System.String[] preTags
    System.String[] postTags
    IEncoder encoder
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    CreateFragments(IndexReader, Int32, String, FieldFragList, Int32)

    Declaration
    public virtual string[] CreateFragments(IndexReader reader, int docId, string fieldName, FieldFragList fieldFragList, int maxNumFragments)
    Parameters
    Type Name Description
    IndexReader reader
    System.Int32 docId
    System.String fieldName
    FieldFragList fieldFragList
    System.Int32 maxNumFragments
    Returns
    Type Description
    System.String[]
    | Improve this Doc View Source

    CreateFragments(IndexReader, Int32, String, FieldFragList, Int32, String[], String[], IEncoder)

    Declaration
    public virtual string[] CreateFragments(IndexReader reader, int docId, string fieldName, FieldFragList fieldFragList, int maxNumFragments, string[] preTags, string[] postTags, IEncoder encoder)
    Parameters
    Type Name Description
    IndexReader reader
    System.Int32 docId
    System.String fieldName
    FieldFragList fieldFragList
    System.Int32 maxNumFragments
    System.String[] preTags
    System.String[] postTags
    IEncoder encoder
    Returns
    Type Description
    System.String[]
    | Improve this Doc View Source

    DiscreteMultiValueHighlighting(IList<FieldFragList.WeightedFragInfo>, Field[])

    Declaration
    protected virtual IList<FieldFragList.WeightedFragInfo> DiscreteMultiValueHighlighting(IList<FieldFragList.WeightedFragInfo> fragInfos, Field[] fields)
    Parameters
    Type Name Description
    IList<FieldFragList.WeightedFragInfo> fragInfos
    Field[] fields
    Returns
    Type Description
    IList<FieldFragList.WeightedFragInfo>
    | Improve this Doc View Source

    GetFields(IndexReader, Int32, String)

    Declaration
    protected virtual Field[] GetFields(IndexReader reader, int docId, string fieldName)
    Parameters
    Type Name Description
    IndexReader reader
    System.Int32 docId
    System.String fieldName
    Returns
    Type Description
    Field[]
    | Improve this Doc View Source

    GetFragmentSource(StringBuilder, Int32[], Field[], Int32, Int32)

    Declaration
    protected virtual string GetFragmentSource(StringBuilder buffer, int[] index, Field[] values, int startOffset, int endOffset)
    Parameters
    Type Name Description
    StringBuilder buffer
    System.Int32[] index
    Field[] values
    System.Int32 startOffset
    System.Int32 endOffset
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    GetFragmentSourceMSO(StringBuilder, Int32[], Field[], Int32, Int32, Int32[])

    Declaration
    protected virtual string GetFragmentSourceMSO(StringBuilder buffer, int[] index, Field[] values, int startOffset, int endOffset, int[] modifiedStartOffset)
    Parameters
    Type Name Description
    StringBuilder buffer
    System.Int32[] index
    Field[] values
    System.Int32 startOffset
    System.Int32 endOffset
    System.Int32[] modifiedStartOffset
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    GetPostTag(Int32)

    Declaration
    protected virtual string GetPostTag(int num)
    Parameters
    Type Name Description
    System.Int32 num
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    GetPostTag(String[], Int32)

    Declaration
    protected virtual string GetPostTag(string[] postTags, int num)
    Parameters
    Type Name Description
    System.String[] postTags
    System.Int32 num
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    GetPreTag(Int32)

    Declaration
    protected virtual string GetPreTag(int num)
    Parameters
    Type Name Description
    System.Int32 num
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    GetPreTag(String[], Int32)

    Declaration
    protected virtual string GetPreTag(string[] preTags, int num)
    Parameters
    Type Name Description
    System.String[] preTags
    System.Int32 num
    Returns
    Type Description
    System.String
    | Improve this Doc View Source

    GetWeightedFragInfoList(IList<FieldFragList.WeightedFragInfo>)

    Declaration
    public abstract IList<FieldFragList.WeightedFragInfo> GetWeightedFragInfoList(IList<FieldFragList.WeightedFragInfo> src)
    Parameters
    Type Name Description
    IList<FieldFragList.WeightedFragInfo> src
    Returns
    Type Description
    IList<FieldFragList.WeightedFragInfo>
    | Improve this Doc View Source

    MakeFragment(StringBuilder, Int32[], Field[], FieldFragList.WeightedFragInfo, String[], String[], IEncoder)

    Declaration
    protected virtual string MakeFragment(StringBuilder buffer, int[] index, Field[] values, FieldFragList.WeightedFragInfo fragInfo, string[] preTags, string[] postTags, IEncoder encoder)
    Parameters
    Type Name Description
    StringBuilder buffer
    System.Int32[] index
    Field[] values
    FieldFragList.WeightedFragInfo fragInfo
    System.String[] preTags
    System.String[] postTags
    IEncoder encoder
    Returns
    Type Description
    System.String

    Implements

    IFragmentsBuilder
    • Improve this Doc
    • View Source
    Back to top Copyright © 2020 Licensed to the Apache Software Foundation (ASF)