Fork me on GitHub
  • API

    Show / Hide Table of Contents

    Class Utility

    SmartChineseAnalyzer utility constants and methods

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Inheritance
    object
    Utility
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Lucene.Net.Analysis.Cn.Smart
    Assembly: Lucene.Net.Analysis.SmartCn.dll
    Syntax
    public static class Utility

    Fields

    COMMON_DELIMITER

    Delimiters will be filtered to this character by SegTokenFilter

    Declaration
    public static readonly char[] COMMON_DELIMITER
    Field Value
    Type Description
    char[]

    END_CHAR_ARRAY

    SmartChineseAnalyzer utility constants and methods

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Declaration
    public static readonly char[] END_CHAR_ARRAY
    Field Value
    Type Description
    char[]

    MAX_FREQUENCE

    Maximum bigram frequency (used in the smoothing function).

    Declaration
    public static readonly int MAX_FREQUENCE
    Field Value
    Type Description
    int

    NUMBER_CHAR_ARRAY

    SmartChineseAnalyzer utility constants and methods

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Declaration
    public static readonly char[] NUMBER_CHAR_ARRAY
    Field Value
    Type Description
    char[]

    SPACES

    Space-like characters that need to be skipped: such as space, tab, newline, carriage return.

    Declaration
    public static readonly string SPACES
    Field Value
    Type Description
    string

    START_CHAR_ARRAY

    SmartChineseAnalyzer utility constants and methods

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Declaration
    public static readonly char[] START_CHAR_ARRAY
    Field Value
    Type Description
    char[]

    STRING_CHAR_ARRAY

    SmartChineseAnalyzer utility constants and methods

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Declaration
    public static readonly char[] STRING_CHAR_ARRAY
    Field Value
    Type Description
    char[]

    Methods

    CompareArray(char[], int, char[], int)

    Compare two arrays starting at the specified offsets.

    Declaration
    public static int CompareArray(char[] larray, int lstartIndex, char[] rarray, int rstartIndex)
    Parameters
    Type Name Description
    char[] larray

    left array

    int lstartIndex

    start offset into larray

    char[] rarray

    right array

    int rstartIndex

    start offset into rarray

    Returns
    Type Description
    int

    0 if the arrays are equal,1 if larray > rarray, -1 if larray < rarray

    CompareArrayByPrefix(char[], int, char[], int)

    Compare two arrays, starting at the specified offsets, but treating shortArray as a prefix to longArray. As long as shortArray is a prefix of longArray, return 0. Otherwise, behave as CompareArray(char[], int, char[], int).

    Declaration
    public static int CompareArrayByPrefix(char[] shortArray, int shortIndex, char[] longArray, int longIndex)
    Parameters
    Type Name Description
    char[] shortArray

    prefix array

    int shortIndex

    offset into shortArray

    char[] longArray

    long array (word)

    int longIndex

    offset into longArray

    Returns
    Type Description
    int

    0 if shortArray is a prefix of longArray, otherwise act as CompareArray(char[], int, char[], int).

    GetCharType(char)

    Return the internal CharType constant of a given character.

    Declaration
    public static CharType GetCharType(char ch)
    Parameters
    Type Name Description
    char ch

    input character

    Returns
    Type Description
    CharType

    Constant from CharType describing the character type.

    See Also
    CharType
    Back to top Copyright © 2024 The Apache Software Foundation, Licensed under the Apache License, Version 2.0
    Apache Lucene.Net, Lucene.Net, Apache, the Apache feather logo, and the Apache Lucene.Net project logo are trademarks of The Apache Software Foundation.
    All other marks mentioned may be trademarks or registered trademarks of their respective owners.