commonMain.net.ormr.fuzzywuzzy.diffutils.structs.kt Maven / Gradle / Ivy
package net.ormr.fuzzywuzzy.diffutils
public enum class EditType {
DELETE,
EQUAL,
INSERT,
REPLACE,
KEEP
}
internal data class EditOp(
val type: EditType,
val sourcePos: Int,
val destinationPos: Int,
) {
override fun toString(): String = "${type.name}($sourcePos, $destinationPos)"
}
internal class MatchingBlock {
var spos: Int = 0
var dpos: Int = 0
var length: Int = 0
override fun toString(): String = "($spos, $dpos, $length)"
}
internal class OpCode {
var type: EditType? = null
var sbeg: Int = 0
var send: Int = 0
var dbeg: Int = 0
var dend: Int = 0
override fun toString(): String = "${type!!.name}($sbeg, $send, $dbeg, $dend)"
}