3 // Object is an encapsulation of an object found in a packfile, or a packed
6 // data is the front-most element of the delta-base chain, and when
7 // resolved, yields the uncompressed data of this object.
9 // typ is the underlying object's type. It is not the type of the
10 // front-most chain element, rather, the type of the actual object.
14 // Unpack resolves the delta-base chain and returns an uncompressed, unpacked,
15 // and full representation of the data encoded by this object.
17 // If there was any error in unpacking this object, it is returned immediately,
18 // and the object's data can be assumed to be corrupt.
19 func (o *Object) Unpack() ([]byte, error) {
20 return o.data.Unpack()
23 // Type returns the underlying object's type. Rather than the type of the
24 // front-most delta-base component, it is the type of the object itself.
25 func (o *Object) Type() PackedObjectType {