aboutsummaryrefslogtreecommitdiffstats
path: root/plumbing/format/packfile/diff_delta.go
diff options
context:
space:
mode:
authorMáximo Cuadros <mcuadros@gmail.com>2017-02-27 12:59:51 +0100
committerGitHub <noreply@github.com>2017-02-27 12:59:51 +0100
commita8f1e517e302569f11fced521c3f091997dac147 (patch)
tree16bbe6118340bfedf35080e66e44a76840fb3afb /plumbing/format/packfile/diff_delta.go
parent39f43b52a2bdfbc73703e2d09b575d49cd70ede8 (diff)
parent059a0be78399cdb0648bd514c5b179819d84403d (diff)
downloadgo-git-a8f1e517e302569f11fced521c3f091997dac147.tar.gz
Merge pull request #288 from ajnavarro/documentation/plumbing
plumbing: improve documentation (Fix #242)
Diffstat (limited to 'plumbing/format/packfile/diff_delta.go')
-rw-r--r--plumbing/format/packfile/diff_delta.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/plumbing/format/packfile/diff_delta.go b/plumbing/format/packfile/diff_delta.go
index 7b2e4ca..c25e194 100644
--- a/plumbing/format/packfile/diff_delta.go
+++ b/plumbing/format/packfile/diff_delta.go
@@ -14,8 +14,10 @@ const (
maxCopyLen = 0xffff
)
-// GetDelta returns an offset delta that knows the way of how to transform
-// base object to target object
+// GetDelta returns an EncodedObject of type OFSDeltaObject. Base and Target object,
+// will be loaded into memory to be able to create the delta object.
+// To generate target again, you will need the obtained object and "base" one.
+// Error will be returned if base or target object cannot be read.
func GetDelta(base, target plumbing.EncodedObject) (plumbing.EncodedObject, error) {
br, err := base.Reader()
if err != nil {