commonMain.com.darkrockstudios.symspellkt.api.StringDistance.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of SymSpellKt-jvm Show documentation
Show all versions of SymSpellKt-jvm Show documentation
A Kotlin Multiplatform implementation of the SymSpell Spell Checking algorithm.
The newest version!
package com.darkrockstudios.symspellkt.api
interface StringDistance {
/**
* Get edit distance between 2 words;
*
* @param w1 String
* @param w2 String
* @return edit distance
*/
fun getDistance(w1: String, w2: String): Double
/**
* Get edit distance between 2 words, if the calculated distance exceeds max provided then return
* maxEditDistance;
*
* @param w1 String
* @param w2 String
* @param maxEditDistance max edit distance possible
* @return edit distance
*/
fun getDistance(w1: String, w2: String, maxEditDistance: Double): Double
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy