Documentation ¶
Index ¶
- func DecodeDownloadFileRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)
- func DecodeDownloadFileSha256Request(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)
- func DecodeListFilesRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)
- func DownloadFileOciPath(repository string) string
- func DownloadFileSha256OciPath(repository string) string
- func EncodeDownloadFileResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error
- func EncodeDownloadFileSha256Response(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error
- func EncodeListFilesResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error
- func ListFilesOciPath(repository string) string
- func Mount(mux goahttp.Muxer, h *Server)
- func MountDownloadFileHandler(mux goahttp.Muxer, h http.Handler)
- func MountDownloadFileSha256Handler(mux goahttp.Muxer, h http.Handler)
- func MountListFilesHandler(mux goahttp.Muxer, h http.Handler)
- func NewDownloadFileHandler(endpoint goa.Endpoint, mux goahttp.Muxer, ...) http.Handler
- func NewDownloadFilePayload(repository string, tag string, file *string, fileRegex *string) *oci.DownloadFilePayload
- func NewDownloadFileSha256Handler(endpoint goa.Endpoint, mux goahttp.Muxer, ...) http.Handler
- func NewDownloadFileSha256Payload(repository string, file string, tag string) *oci.DownloadFileSha256Payload
- func NewListFilesHandler(endpoint goa.Endpoint, mux goahttp.Muxer, ...) http.Handler
- func NewListFilesPayload(repository string, tag string) *oci.ListFilesPayload
- type MountPoint
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeDownloadFileRequest ¶
func DecodeDownloadFileRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)
DecodeDownloadFileRequest returns a decoder for requests sent to the oci download-file endpoint.
func DecodeDownloadFileSha256Request ¶
func DecodeDownloadFileSha256Request(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)
DecodeDownloadFileSha256Request returns a decoder for requests sent to the oci download-file-sha256 endpoint.
func DecodeListFilesRequest ¶
func DecodeListFilesRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)
DecodeListFilesRequest returns a decoder for requests sent to the oci list-files endpoint.
func DownloadFileOciPath ¶
DownloadFileOciPath returns the URL path to the oci service download-file HTTP endpoint.
func DownloadFileSha256OciPath ¶
DownloadFileSha256OciPath returns the URL path to the oci service download-file-sha256 HTTP endpoint.
func EncodeDownloadFileResponse ¶
func EncodeDownloadFileResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error
EncodeDownloadFileResponse returns an encoder for responses returned by the oci download-file endpoint.
func EncodeDownloadFileSha256Response ¶
func EncodeDownloadFileSha256Response(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error
EncodeDownloadFileSha256Response returns an encoder for responses returned by the oci download-file-sha256 endpoint.
func EncodeListFilesResponse ¶
func EncodeListFilesResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error
EncodeListFilesResponse returns an encoder for responses returned by the oci list-files endpoint.
func ListFilesOciPath ¶
ListFilesOciPath returns the URL path to the oci service list-files HTTP endpoint.
func MountDownloadFileHandler ¶
MountDownloadFileHandler configures the mux to serve the "oci" service "download-file" endpoint.
func MountDownloadFileSha256Handler ¶
MountDownloadFileSha256Handler configures the mux to serve the "oci" service "download-file-sha256" endpoint.
func MountListFilesHandler ¶
MountListFilesHandler configures the mux to serve the "oci" service "list-files" endpoint.
func NewDownloadFileHandler ¶
func NewDownloadFileHandler( endpoint goa.Endpoint, mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder, encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, errhandler func(context.Context, http.ResponseWriter, error), formatter func(ctx context.Context, err error) goahttp.Statuser, ) http.Handler
NewDownloadFileHandler creates a HTTP handler which loads the HTTP request and calls the "oci" service "download-file" endpoint.
func NewDownloadFilePayload ¶
func NewDownloadFilePayload(repository string, tag string, file *string, fileRegex *string) *oci.DownloadFilePayload
NewDownloadFilePayload builds a oci service download-file endpoint payload.
func NewDownloadFileSha256Handler ¶
func NewDownloadFileSha256Handler( endpoint goa.Endpoint, mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder, encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, errhandler func(context.Context, http.ResponseWriter, error), formatter func(ctx context.Context, err error) goahttp.Statuser, ) http.Handler
NewDownloadFileSha256Handler creates a HTTP handler which loads the HTTP request and calls the "oci" service "download-file-sha256" endpoint.
func NewDownloadFileSha256Payload ¶
func NewDownloadFileSha256Payload(repository string, file string, tag string) *oci.DownloadFileSha256Payload
NewDownloadFileSha256Payload builds a oci service download-file-sha256 endpoint payload.
func NewListFilesHandler ¶
func NewListFilesHandler( endpoint goa.Endpoint, mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder, encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, errhandler func(context.Context, http.ResponseWriter, error), formatter func(ctx context.Context, err error) goahttp.Statuser, ) http.Handler
NewListFilesHandler creates a HTTP handler which loads the HTTP request and calls the "oci" service "list-files" endpoint.
func NewListFilesPayload ¶
func NewListFilesPayload(repository string, tag string) *oci.ListFilesPayload
NewListFilesPayload builds a oci service list-files endpoint payload.
Types ¶
type MountPoint ¶
type MountPoint struct { // Method is the name of the service method served by the mounted HTTP handler. Method string // Verb is the HTTP method used to match requests to the mounted handler. Verb string // Pattern is the HTTP request path pattern used to match requests to the // mounted handler. Pattern string }
MountPoint holds information about the mounted endpoints.
type Server ¶
type Server struct { Mounts []*MountPoint ListFiles http.Handler DownloadFile http.Handler DownloadFileSha256 http.Handler }
Server lists the oci service endpoint HTTP handlers.
func New ¶
func New( e *oci.Endpoints, mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder, encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, errhandler func(context.Context, http.ResponseWriter, error), formatter func(ctx context.Context, err error) goahttp.Statuser, ) *Server
New instantiates HTTP handlers for all the oci service endpoints using the provided encoder and decoder. The handlers are mounted on the given mux using the HTTP verb and path defined in the design. errhandler is called whenever a response fails to be encoded. formatter is used to format errors returned by the service methods prior to encoding. Both errhandler and formatter are optional and can be nil.
func (*Server) MethodNames ¶
MethodNames returns the methods served.