···22// higher-level object queries.
33//
44// Fetching is above [objectstore]: it parses stored objects into blobs, trees,
55-// commits, and tags, peels tree-ish or commit-ish objects, resolves paths
66-// within trees, and can expose one tree as an [io/fs] view.
55+// commits, and tags, exposes object metadata, peels tree-ish or commit-ish
66+// objects, resolves paths within trees, and can expose one tree as an [io/fs]
77+// view.
78package fetch
-18
object/fetch/exact_commit_reader.go
···11-package fetch
22-33-import (
44- "io"
55-66- objectid "codeberg.org/lindenii/furgit/object/id"
77- objecttype "codeberg.org/lindenii/furgit/object/type"
88-)
99-1010-// ExactCommitReader returns a reader for the content of the commit at id,
1111-// together with its content size in bytes.
1212-//
1313-// Usage of this method is unusual.
1414-//
1515-// Labels: Life-Parent, Close-Caller.
1616-func (r *Fetcher) ExactCommitReader(id objectid.ObjectID) (io.ReadCloser, int64, error) {
1717- return r.exactReader(id, objecttype.TypeCommit)
1818-}
-18
object/fetch/exact_tag_reader.go
···11-package fetch
22-33-import (
44- "io"
55-66- objectid "codeberg.org/lindenii/furgit/object/id"
77- objecttype "codeberg.org/lindenii/furgit/object/type"
88-)
99-1010-// ExactTagReader returns a reader for the content of the tag at id,
1111-// together with its content size in bytes.
1212-//
1313-// Usage of this method is unusual.
1414-//
1515-// Labels: Life-Parent, Close-Caller.
1616-func (r *Fetcher) ExactTagReader(id objectid.ObjectID) (io.ReadCloser, int64, error) {
1717- return r.exactReader(id, objecttype.TypeTag)
1818-}
-18
object/fetch/exact_tree_reader.go
···11-package fetch
22-33-import (
44- "io"
55-66- objectid "codeberg.org/lindenii/furgit/object/id"
77- objecttype "codeberg.org/lindenii/furgit/object/type"
88-)
99-1010-// ExactTreeReader returns a reader for the content of the tree at id,
1111-// together with its content size in bytes.
1212-//
1313-// Usage of this method is unusual.
1414-//
1515-// Labels: Life-Parent, Close-Caller.
1616-func (r *Fetcher) ExactTreeReader(id objectid.ObjectID) (io.ReadCloser, int64, error) {
1717- return r.exactReader(id, objecttype.TypeTree)
1818-}
+4-1
object/fetch/fetcher.go
···2233import objectstore "codeberg.org/lindenii/furgit/object/store"
4455-// Fetcher resolves parsed and streamed objects from an object store.
55+// Fetcher provides ordinary object access above an object store.
66+//
77+// It exposes object metadata, typed object loading, tree-ish and commit-ish
88+// peeling, path resolution, one-tree fs views, and blob content streaming.
69//
710// Labels: MT-Safe.
811type Fetcher struct {