aboutsummaryrefslogtreecommitdiffstats
path: root/plumbing/format/packfile/diff_delta.go
diff options
context:
space:
mode:
authorAntonio Jesus Navarro Perez <antonio@sourced.tech>2017-02-23 17:07:08 +0100
committerAntonio Jesus Navarro Perez <antonio@sourced.tech>2017-02-23 17:14:43 +0100
commit059a0be78399cdb0648bd514c5b179819d84403d (patch)
tree007fea2e8529b865b354b45c8aed9045e136d462 /plumbing/format/packfile/diff_delta.go
parentb5da4e98571b02dc106de4f9b2cb2a298489f1b1 (diff)
downloadgo-git-059a0be78399cdb0648bd514c5b179819d84403d.tar.gz
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 {