Struct Diff<T>

Namespace
Pixie
Assembly
Pixie.dll

Represents the changes required to turn one sequence into another.

public struct Diff<T> : IEquatable<Diff<T>>

Type Parameters

T
Implements
Inherited Members

Constructors

Diff(IReadOnlyList<DiffElement<T>>)

Creates a diff from a sequence of diff elements.

public Diff(IReadOnlyList<DiffElement<T>> elements)

Parameters

elements IReadOnlyList<DiffElement<T>>

The diff elements.

Properties

Elements

Gets the elements in this diff.

public readonly IReadOnlyList<DiffElement<T>> Elements { get; }

Property Value

IReadOnlyList<DiffElement<T>>

The diff elements.

NewSequence

Recreates the new sequence, that is, the sequence produced by applying this diff.

public IReadOnlyList<T> NewSequence { get; }

Property Value

IReadOnlyList<T>

The new sequence.

OldSequence

Recreates the old sequence, that is, the sequence prior to applying this diff.

public IReadOnlyList<T> OldSequence { get; }

Property Value

IReadOnlyList<T>

The old sequence.

Methods

Equals(Diff<T>)

Tests if this diff is the same as another diff.

public bool Equals(Diff<T> other)

Parameters

other Diff<T>

The other diff.

Returns

bool

true if this diff equals the other diff; otherwise, false.

Equals(object)

public override bool Equals(object obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

ToString()

public override string ToString()

Returns

string