braskit/diff

This package is abandoned and no longer maintained. No replacement package was suggested.

Diffs two strings and generates an object graph

v1.0.1 2015-04-18 06:16 UTC

README

Braskit\Diff is a PHP library which diffs two strings and generates an object graph. It was conceived because Sebastian Bergmann's Diff library isn't capable of parsing its own diffs (due to the output not being unified or whatever), while this library, which does parse unified diffs, doesn't generate a usable object graph. Braskit\Diff solves this problem by providing the needed glue between the two libraries.

Usage

<?php

use Braskit\Diff\Diff;

$differ = new Braskit\Diff\Diff();

$graph = $differ->diffStrings($one, $two);

The resulting object graph is a SebastianBergmann\Diff\Diff instance.

Licence

MIT