UnifiedDiff class final

A file diff format that closely resembles the diffutils unified output format.

Annotations
  • @immutable

Constructors

UnifiedDiff.fromPatch(Patch<String> patch, {required UnifiedDiffHeader header, int context = 3, UnifiedDiffHunkHeaderConfig hunkHeaderConfig = const UnifiedDiffHunkHeaderConfig()})
Create a UnifiedDiff from the specified patch using the information from the header.
factory

Properties

hashCode → int
The hash code for this object.
no setterinherited
The header of this diff, often containing information such as source and target filename.
final
hunks → Iterable<UnifiedDiffHunk>
The hunks of differences this diff is composed of.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toPatch() → Patch<String>
Convert a UnifiedDiff back to a Patch between the source and target files.
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited