Documentation
¶
Index ¶
- type API
- func (a *API) ProfileGreaterThanVersionHandler(w http.ResponseWriter, r *http.Request)
- func (a *API) ProfileHandler(w http.ResponseWriter, r *http.Request)
- func (a *API) ProfileWithVersionHandler(w http.ResponseWriter, r *http.Request)
- func (a *API) ProfilesHandler(w http.ResponseWriter, r *http.Request)
- type Catalog
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API struct {
*mux.Router
// contains filtered or unexported fields
}
API defines a catalog router.
func New ¶
func New(profileCatalog Catalog, logger logr.Logger) API
New returns a new mux based api router.
func (*API) ProfileGreaterThanVersionHandler ¶ added in v0.0.4
func (a *API) ProfileGreaterThanVersionHandler(w http.ResponseWriter, r *http.Request)
ProfileGreaterThanVersionHandler is the handler for /profiles/{catalog}/{profile}/{version}/available_updates requests.
func (*API) ProfileHandler ¶
func (a *API) ProfileHandler(w http.ResponseWriter, r *http.Request)
ProfileHandler is the handler for /profiles/{catalog}/{profile} requests.
func (*API) ProfileWithVersionHandler ¶ added in v0.0.2
func (a *API) ProfileWithVersionHandler(w http.ResponseWriter, r *http.Request)
ProfileWithVersionHandler is the handler for /profiles/{catalog}/{profile}/{version} requests.
func (*API) ProfilesHandler ¶
func (a *API) ProfilesHandler(w http.ResponseWriter, r *http.Request)
ProfilesHandler is the handler for /profiles requests.
type Catalog ¶
type Catalog interface {
// Get will return a specific profile from the catalog
Get(sourceName, profileName string) *profilesv1.ProfileCatalogEntry
// GetWithVersion will return a specific profile from the catalog
GetWithVersion(logger logr.Logger, sourceName, profileName, version string) *profilesv1.ProfileCatalogEntry
// ProfilesGreaterThanVersion returns all profiles which are of a greater version for a given profile with a version.
ProfilesGreaterThanVersion(logger logr.Logger, sourceName, profileName, version string) []profilesv1.ProfileCatalogEntry
// Search will return a list of profiles which match query
Search(query string) []profilesv1.ProfileCatalogEntry
}
Catalog is an interface for the Catalog
Click to show internal directories.
Click to hide internal directories.