codes.quine.labo.lite.gestalt

Type members

Classlikes

object Gestalt

Gestalt is a frontend object of diff computation.

Gestalt is a frontend object of diff computation.

final case class Hunk(leftStart: Int, leftEnd: Int, rightStart: Int, rightEnd: Int)

Hunk is a hunk of diff.

Hunk is a hunk of diff.

We can get the right sequence from the left sequence by replacing left.slice(leftStart, leftEnd) with right.slice(rightStart, rightEnd).

final case class Patch[A](left: IndexedSeq[A], right: IndexedSeq[A], hunks: Seq[Hunk])

Patch is a result of diff operation.

Patch is a result of diff operation.

Note that this data class is not for patching purpose against its naming, but it is for generating a patch string like unified format. This contains original sequences for such a purpose.