I want the Go utility package to expose GenerateRepoURLs(url string, externalTagsOrDigest func(string, string) ([]string, error)) ([]*RepoURL, error) as a one-shot parser and expander for Docker image references. When I call it with "nginx:v1" and a tag provider that would return []string{"latest"}, it should return one RepoURL whose String() is docker.io/library/nginx:v1, GetRegistry() is docker.io, GetRepo() is library/nginx, and GetTagOrDigest() is v1; the provider should not be consulted for this concrete tag. When I call it with "127.0.0.1:300/library/nginx:v1,v2", it should return two entries for the same registry and repository, preserving the tag order v1, then v2.
If the URL has no tag or digest, such as "registry.hub.docker.io/library/nginx", the function should call the supplied tag provider with registry registry.hub.docker.io and repository library/nginx, then return one RepoURL per provided tag using those tags in provider order. If the URL uses a tag regex like "test-regex/test:/b+/", it should fetch all tags through the provider, compile the regex between the slashes, and return only matching tags; for provider output []string{"aaa", "bbb"}, the result should contain only tag bbb. If the URL uses a digest like "registry.cn-beijing.aliyuncs.com/hhyasdf/hybridnet@sha256:df2ef9e979fc063645dcbed51374233c6bcf4ab49308c0478702565e96b9bc9e", the returned RepoURL should preserve that digest, use @ in GetRepoWithTagOrDigest(), and report repository hhyasdf/hybridnet.
Invalid input should return a non-nil error instead of partial results: a regex tag must have both leading and trailing /, an invalid regex should report a regex error, an invalid repository reference should report a parse error, and an error returned by the tag provider should be propagated with context. For the same input and a deterministic tag provider, repeated calls should produce equal ordered results. The function should not write files, perform network access directly, or keep hidden global state; all external tag lookup must happen through the supplied callback.