]> source.dussan.org Git - jgit.git/commit
Add helper methods to Edit 01/1501/3
authorShawn O. Pearce <spearce@spearce.org>
Thu, 2 Sep 2010 06:09:48 +0000 (23:09 -0700)
committerShawn O. Pearce <spearce@spearce.org>
Sat, 4 Sep 2010 06:55:46 +0000 (23:55 -0700)
commitfe8fe13349bb46ae690cfea6d3e57bfdac2301e4
tree8c4740ab796a0ce909d5cfbbb3cf46329cf39bd6
parent596c3f668b184e41b147aab6260c23189e521c09
Add helper methods to Edit

Exposing isEmpty, getLengthA, getLengthB make it easier to examine
the state of an edit and work with it from higher level code.

The before and after cut routines make it easy to split an edit
that contains another edit, such as to decompose a REPLACE that
contains a common sequence within it.

Change-Id: Id63d6476a7a6b23acb7ab237d414a0a1a7200290
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
org.eclipse.jgit.test/tst/org/eclipse/jgit/diff/EditTest.java
org.eclipse.jgit/src/org/eclipse/jgit/diff/Edit.java