All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.marklogic.client.expression.SpellExpr Maven / Gradle / Ivy

The newest version!
/*
 * Copyright © 2024 MarkLogic Corporation. All Rights Reserved.
 */

package com.marklogic.client.expression;

import com.marklogic.client.type.XsIntegerVal;
import com.marklogic.client.type.XsStringSeqVal;
import com.marklogic.client.type.XsStringVal;

import com.marklogic.client.type.ServerExpression;

// IMPORTANT: Do not edit. This file is generated.

/**
 * Builds expressions to call functions in the spell server library for a row
 * pipeline.
 */
public interface SpellExpr {
    /**
  * Given a word returns the two metaphone keys. The primary and secondary metaphone keys which represent the phonetic encoding of two words are returned as a sequence of two strings. Double metaphone is an algorithm based on phonetic sounds useful in providing data to spelling correction suggestions.
  *
  * 

  * 

* Provides a client interface to the spell:double-metaphone server function. * @param word The word for phonetic matching. (of xs:string) * @return a server expression with the xs:string server data type */ public ServerExpression doubleMetaphone(ServerExpression word); /** * Given two strings, returns the Levenshtein distance between those strings. The Levenshtein distance is a measure of how many operations it takes to transform a string into another string, and it is useful in determining if a word is spelled correctly, or in simply comparing how "different" two words are. *

* Provides a client interface to the spell:levenshtein-distance server function. * @param str1 The first input string. (of xs:string) * @param str2 The second input string. (of xs:string) * @return a server expression with the xs:integer server data type */ public ServerExpression levenshteinDistance(ServerExpression str1, String str2); /** * Given two strings, returns the Levenshtein distance between those strings. The Levenshtein distance is a measure of how many operations it takes to transform a string into another string, and it is useful in determining if a word is spelled correctly, or in simply comparing how "different" two words are. * * *

* Provides a client interface to the spell:levenshtein-distance server function. * @param str1 The first input string. (of xs:string) * @param str2 The second input string. (of xs:string) * @return a server expression with the xs:integer server data type */ public ServerExpression levenshteinDistance(ServerExpression str1, ServerExpression str2); /** * Returns the romanization of the string, substituting basic Latin letters for the letters in the string, according to their sound. Unsupported characters will be mapped to '?' for compatibility with the double metaphone algorithm. We support romanization of the scripts of the languages with advanced support in MarkLogic except for Chinese characters and Hangul. * * *

* Provides a client interface to the spell:romanize server function. * @param string The input string. (of xs:string) * @return a server expression with the xs:string server data type */ public ServerExpression romanize(ServerExpression string); }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy