Documentation ¶
Index ¶
- type Storage
- func (s *Storage) Catalog(ctx context.Context, token string, pageSize int) ([]paths.AllPathParams, string, error)
- func (s *Storage) Delete(ctx context.Context, module string, version string) error
- func (s *Storage) Exists(ctx context.Context, module string, version string) (bool, error)
- func (s *Storage) GoMod(ctx context.Context, module string, version string) ([]byte, error)
- func (s *Storage) Info(ctx context.Context, module string, version string) ([]byte, error)
- func (s *Storage) List(ctx context.Context, module string) ([]string, error)
- func (s *Storage) Save(ctx context.Context, module, version string, mod []byte, zip io.Reader, ...) error
- func (s *Storage) Zip(ctx context.Context, module string, version string) (io.ReadCloser, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Storage ¶
type Storage struct {
// contains filtered or unexported fields
}
Storage implements (github.com/gomods/athens/pkg/storage).Saver and also provides a function to fetch the location of a module
func (*Storage) Catalog ¶ added in v0.6.0
func (s *Storage) Catalog(ctx context.Context, token string, pageSize int) ([]paths.AllPathParams, string, error)
Catalog implements the (./pkg/storage).Catalog interface It returns a list of versions, if any, for a given module
func (*Storage) Delete ¶
Delete implements the (./pkg/storage).Deleter interface and removes a version of a module from storage. Returning ErrNotFound if the version does not exist.
func (*Storage) Exists ¶
Exists implements the (./pkg/storage).Checker interface returning true if the module at version exists in storage
func (*Storage) List ¶
List implements the (./pkg/storage).Lister interface It returns a list of versions, if any, for a given module
Click to show internal directories.
Click to hide internal directories.