public class GDiffPatcher
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private java.nio.ByteBuffer |
buf |
private byte[] |
buf2 |
Constructor and Description |
---|
GDiffPatcher()
Constructs a new GDiffPatcher.
|
Modifier and Type | Method and Description |
---|---|
private void |
append(int length,
java.io.InputStream patch,
java.io.OutputStream output) |
private void |
copy(long offset,
int length,
SeekableSource source,
java.io.OutputStream output) |
static void |
main(java.lang.String[] argv)
Simple command line tool to patch a file.
|
byte[] |
patch(byte[] source,
byte[] patch)
Patches in memory, returning the patch result.
|
void |
patch(byte[] source,
java.io.InputStream patch,
java.io.OutputStream output)
Patches to an output stream.
|
void |
patch(java.io.File sourceFile,
java.io.File patchFile,
java.io.File outputFile)
Patches to an output file.
|
void |
patch(SeekableSource source,
java.io.InputStream patch,
java.io.OutputStream out)
Patches to an output stream.
|
public void patch(java.io.File sourceFile, java.io.File patchFile, java.io.File outputFile) throws java.io.IOException
java.io.IOException
public void patch(byte[] source, java.io.InputStream patch, java.io.OutputStream output) throws java.io.IOException
java.io.IOException
public byte[] patch(byte[] source, byte[] patch) throws java.io.IOException
java.io.IOException
public void patch(SeekableSource source, java.io.InputStream patch, java.io.OutputStream out) throws java.io.IOException
java.io.IOException
private void copy(long offset, int length, SeekableSource source, java.io.OutputStream output) throws java.io.IOException
java.io.IOException
private void append(int length, java.io.InputStream patch, java.io.OutputStream output) throws java.io.IOException
java.io.IOException
public static void main(java.lang.String[] argv)