Files
wehub-resource-sync 48b3ccf279
gitleaks / gitleaks (push) Has been skipped
Test / test (ubuntu-latest) (push) Failing after 0s
Test / test (windows-latest) (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:12:29 +08:00

17 lines
425 B
Go

package sources
import (
"context"
)
// FragmentsFunc is the type of function called by Fragments to yield the next
// fragment
type FragmentsFunc func(fragment Fragment, err error) error
// Source is a thing that can yield fragments
type Source interface {
// Fragments provides a filepath.WalkDir like interface for scanning the
// fragments in the source
Fragments(ctx context.Context, yield FragmentsFunc) error
}