org.eclipse.jgit.lib
Class BinaryDelta

java.lang.Object
  extended by org.eclipse.jgit.lib.BinaryDelta

public class BinaryDelta
extends java.lang.Object

Recreate a stream from a base stream and a GIT pack delta.

This entire class is heavily cribbed from patch-delta.c in the GIT project. The original delta patching code was written by Nicolas Pitre (<nico@cam.org>).


Constructor Summary
BinaryDelta()
           
 
Method Summary
static byte[] apply(byte[] base, byte[] delta)
          Apply the changes defined by delta to the data in base, yielding a new array of bytes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BinaryDelta

public BinaryDelta()
Method Detail

apply

public static final byte[] apply(byte[] base,
                                 byte[] delta)
Apply the changes defined by delta to the data in base, yielding a new array of bytes.

Parameters:
base - some byte representing an object of some kind.
delta - a git pack delta defining the transform from one version to another.
Returns:
patched base