Fork me on GitHub
  • API

    Show / Hide Table of Contents

    Class PhoneticEngine

    Converts words into potential phonetic representations.

    Inheritance
    object
    PhoneticEngine
    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.Phonetic.Language.Bm
    Assembly: Lucene.Net.Analysis.Phonetic.dll
    Syntax
    public class PhoneticEngine
    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    Constructors

    PhoneticEngine(NameType, RuleType, bool)

    Generates a new, fully-configured phonetic engine.

    Declaration
    public PhoneticEngine(NameType nameType, RuleType ruleType, bool concat)
    Parameters
    Type Name Description
    NameType nameType

    The type of names it will use.

    RuleType ruleType

    The type of rules it will apply.

    bool concat

    If it will concatenate multiple encodings.

    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    PhoneticEngine(NameType, RuleType, bool, int)

    Generates a new, fully-configured phonetic engine.

    since 1.7
    Declaration
    public PhoneticEngine(NameType nameType, RuleType ruleType, bool concat, int maxPhonemes)
    Parameters
    Type Name Description
    NameType nameType

    The type of names it will use.

    RuleType ruleType

    The type of rules it will apply.

    bool concat

    If it will concatenate multiple encodings.

    int maxPhonemes

    The maximum number of phonemes that will be handled.

    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    Properties

    IsConcat

    Gets if multiple phonetic encodings are concatenated or if just the first one is kept. Returns true if multiple phonetic encodings are returned, false if just the first is.

    Declaration
    public virtual bool IsConcat { get; }
    Property Value
    Type Description
    bool
    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    Lang

    Gets the Lang language guessing rules being used.

    Declaration
    public virtual Lang Lang { get; }
    Property Value
    Type Description
    Lang
    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    MaxPhonemes

    Gets the maximum number of phonemes the engine will calculate for a given input.

    since 1.7
    Declaration
    public virtual int MaxPhonemes { get; }
    Property Value
    Type Description
    int
    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    NameType

    Gets the NameType being used.

    Declaration
    public virtual NameType NameType { get; }
    Property Value
    Type Description
    NameType
    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    RuleType

    Gets the RuleType being used.

    Declaration
    public virtual RuleType RuleType { get; }
    Property Value
    Type Description
    RuleType
    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    Methods

    Encode(string)

    Encodes a string to its phonetic representation.

    Declaration
    public virtual string Encode(string input)
    Parameters
    Type Name Description
    string input

    The string to encode.

    Returns
    Type Description
    string

    The encoding of the input.

    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6

    Encode(string, LanguageSet)

    Encodes an input string into an output phonetic representation, given a set of possible origin languages.

    Declaration
    public virtual string Encode(string input, LanguageSet languageSet)
    Parameters
    Type Name Description
    string input

    String to phoneticise; a string with dashes or spaces separating each word.

    LanguageSet languageSet
    Returns
    Type Description
    string

    A phonetic representation of the input; a string containing '-'-separated phonetic representations of the input.

    Remarks

    This is a two-stage process. Firstly, the word is converted into a phonetic representation that takes into account the likely source language. Next, this phonetic representation is converted into a pan-European 'average' representation, allowing comparison between different versions of essentially the same word from different languages.

    This class is intentionally immutable and thread-safe. If you wish to alter the settings for a PhoneticEngine, you must make a new one with the updated settings.

    Ported from phoneticengine.php

    since 1.6
    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.