Collection

protocol Collection : Sequence where Self.SubSequence : Collection
  • Creates a diff between the calee and other collection

    Complexity

    O((N+M)*D)

    Declaration

    Swift

    public func diff(
        _ other: Self,
        isEqual: EqualityChecker<Self>
        ) -> Diff

    Parameters

    other

    a collection to compare the calee to

    Return Value

    a Diff between the calee and other collection

  • Generates all traces required to create an output diff. See the paper for more information on traces.

    Declaration

    Swift

    public func diffTraces(
        to: Self,
        isEqual: EqualityChecker<Self>
        ) -> [Trace]

    Parameters

    to

    other collection

    Return Value

    all traces required to create an output diff

  • Returns the traces which mark the shortest diff path.

    Declaration

    Swift

    public func outputDiffPathTraces(
        to: Self,
        isEqual: EqualityChecker<Self>
        ) -> [Trace]