aboutsummaryrefslogtreecommitdiff
path: root/ref
diff options
context:
space:
mode:
authorGravatar Runxi Yu2026-03-31 02:40:34 +0000
committerGravatar Runxi Yu2026-03-31 02:40:34 +0000
commitda6764565629b0376f8d505bdd9d5fdc9c567f93 (patch)
tree6b855e5e4ba9c740f76016f42c1bb5ebd9fb9447 /ref
parentobject/fetch: Remove peel to tag functions (diff)
signatureNo signature
ref/store: Simplify names v0.1.166
Diffstat (limited to 'ref')
-rw-r--r--ref/store/batch_store.go4
-rw-r--r--ref/store/chain/chain.go2
-rw-r--r--ref/store/chain/new.go4
-rw-r--r--ref/store/files/store.go6
-rw-r--r--ref/store/reading.go4
-rw-r--r--ref/store/transactional_store.go6
6 files changed, 13 insertions, 13 deletions
diff --git a/ref/store/batch_store.go b/ref/store/batch_store.go
index b6cd9adf..725a05e5 100644
--- a/ref/store/batch_store.go
+++ b/ref/store/batch_store.go
@@ -1,7 +1,7 @@
package refstore
-// BatchStore begins non-atomic reference batches.
-type BatchStore interface {
+// Batcher begins non-atomic reference batches.
+type Batcher interface {
// BeginBatch creates one new queued batch.
//
// Labels: Life-Parent.
diff --git a/ref/store/chain/chain.go b/ref/store/chain/chain.go
index 302d7f88..a332f64c 100644
--- a/ref/store/chain/chain.go
+++ b/ref/store/chain/chain.go
@@ -8,5 +8,5 @@ import refstore "codeberg.org/lindenii/furgit/ref/store"
//
// Labels: Close-Caller.
type Chain struct {
- backends []refstore.ReadingStore
+ backends []refstore.Reader
}
diff --git a/ref/store/chain/new.go b/ref/store/chain/new.go
index 2b720e48..1c8a3a28 100644
--- a/ref/store/chain/new.go
+++ b/ref/store/chain/new.go
@@ -7,8 +7,8 @@ import refstore "codeberg.org/lindenii/furgit/ref/store"
// The provided backends must be non-nil and distinct.
//
// Labels: Deps-Borrowed, Life-Parent.
-func New(backends ...refstore.ReadingStore) *Chain {
+func New(backends ...refstore.Reader) *Chain {
return &Chain{
- backends: append([]refstore.ReadingStore(nil), backends...),
+ backends: append([]refstore.Reader(nil), backends...),
}
}
diff --git a/ref/store/files/store.go b/ref/store/files/store.go
index 9e548af5..66d46d06 100644
--- a/ref/store/files/store.go
+++ b/ref/store/files/store.go
@@ -25,7 +25,7 @@ type Store struct {
}
var (
- _ refstore.ReadingStore = (*Store)(nil)
- _ refstore.TransactionalStore = (*Store)(nil)
- _ refstore.BatchStore = (*Store)(nil)
+ _ refstore.Reader = (*Store)(nil)
+ _ refstore.Transactioner = (*Store)(nil)
+ _ refstore.Batcher = (*Store)(nil)
)
diff --git a/ref/store/reading.go b/ref/store/reading.go
index 07814c00..a9e2ad49 100644
--- a/ref/store/reading.go
+++ b/ref/store/reading.go
@@ -2,10 +2,10 @@ package refstore
import "codeberg.org/lindenii/furgit/ref"
-// ReadingStore reads Git references.
+// Reader reads Git references.
//
// Labels: MT-Safe.
-type ReadingStore interface {
+type Reader interface {
// Resolve resolves a reference name to either a symbolic or detached ref.
//
// Implementations should return value forms ([ref.Detached] or [ref.Symbolic]),
diff --git a/ref/store/transactional_store.go b/ref/store/transactional_store.go
index 8a061f54..10f4543a 100644
--- a/ref/store/transactional_store.go
+++ b/ref/store/transactional_store.go
@@ -1,11 +1,11 @@
package refstore
-// TransactionalStore begins atomic reference transactions.
+// Transactioner begins atomic reference transactions.
//
// Not every readable reference store is writable. Implementations should only
-// satisfy TransactionalStore when they can stage and commit reference updates
+// satisfy Transactioner when they can stage and commit reference updates
// atomically within that backend.
-type TransactionalStore interface {
+type Transactioner interface {
// BeginTransaction creates one new mutable transaction.
//
// Labels: Life-Parent.