diff options
author | Máximo Cuadros <mcuadros@gmail.com> | 2017-07-27 18:04:00 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-07-27 18:04:00 +0200 |
commit | 86f33ed017b55898758bf8900a085f355b2793d0 (patch) | |
tree | 1e741bed0672a7afb62cda37ca0b1d86fad52889 /plumbing/storer/object.go | |
parent | 7b08a3005480a50f0f4290aff8f3702085d5e30d (diff) | |
parent | 16b24f84e9342234ad90da27a6532887b05d1965 (diff) | |
download | go-git-86f33ed017b55898758bf8900a085f355b2793d0.tar.gz |
Merge pull request #515 from smola/reuse-packed-objects
storage: reuse deltas from packfiles
Diffstat (limited to 'plumbing/storer/object.go')
-rw-r--r-- | plumbing/storer/object.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/plumbing/storer/object.go b/plumbing/storer/object.go index a733ee6..3f41468 100644 --- a/plumbing/storer/object.go +++ b/plumbing/storer/object.go @@ -38,6 +38,14 @@ type EncodedObjectStorer interface { IterEncodedObjects(plumbing.ObjectType) (EncodedObjectIter, error) } +// DeltaObjectStorer is an EncodedObjectStorer that can return delta +// objects. +type DeltaObjectStorer interface { + // DeltaObject is the same as EncodedObject but without resolving deltas. + // Deltas will be returned as plumbing.DeltaObject instances. + DeltaObject(plumbing.ObjectType, plumbing.Hash) (plumbing.EncodedObject, error) +} + // Transactioner is a optional method for ObjectStorer, it enable transaction // base write and read operations in the storage type Transactioner interface { |