patch_apply method

List patch_apply(
  1. List<Patch> patches,
  2. String text
)

Merge a set of patches onto the text. Return a patched text, as well as an array of true/false values indicating which patches were applied.

  • patches is a List of Patch objects
  • text is the old text.

Returns a two element List, containing the new text and a List of bool values.

Implementation

List patch_apply(List<p.Patch> patches, String text) {
  return p.patchApply(patches, text, diffTimeout: diffTimeout,
      deleteThreshold: patchDeleteThreshold, margin: patchMargin);
}