Skip to content

Commit ee5335b

Browse files
author
Michal Minář
committed
godoc'd
Signed-off-by: Michal Minář <[email protected]>
1 parent e7e4108 commit ee5335b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pkg/dockerregistry/server/catalog.go

+5
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,17 @@ type RepositoryEnumerator interface {
2727
EnumerateRepositories(ctx context.Context, repos []string, last string) (n int, err error)
2828
}
2929

30+
// cachingRepositoryEnumerator is an enumerator that supports chunking by caching associations between
31+
// repository names and opaque continuation tokens.
3032
type cachingRepositoryEnumerator struct {
3133
client client.RegistryClient
3234
// a cache of opaque continue tokens for repository enumeration
3335
cache *cache.LRUExpireCache
3436
}
3537

38+
var _ RepositoryEnumerator = &cachingRepositoryEnumerator{}
39+
40+
// NewCachingRepositoryEnumerator returns a new caching repository enumerator.
3641
func NewCachingRepositoryEnumerator(client client.RegistryClient, cache *cache.LRUExpireCache) RepositoryEnumerator {
3742
return &cachingRepositoryEnumerator{
3843
client: client,

0 commit comments

Comments
 (0)