Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MountHealthController ¶
func MountHealthController(service *goa.Service, ctrl HealthController)
MountHealthController "mounts" a Health resource controller on the given service.
func MountKeysController ¶
func MountKeysController(service *goa.Service, ctrl KeysController)
MountKeysController "mounts" a Keys resource controller on the given service.
Types ¶
type HealthController ¶
type HealthController interface { goa.Muxer Healthcheck(*HealthcheckHealthContext) error }
HealthController is the controller interface for the Health actions.
type HealthcheckHealthContext ¶
type HealthcheckHealthContext struct { context.Context *goa.ResponseData *goa.RequestData }
HealthcheckHealthContext provides the health healthcheck action context.
func NewHealthcheckHealthContext ¶
func NewHealthcheckHealthContext(ctx context.Context, r *http.Request, service *goa.Service) (*HealthcheckHealthContext, error)
NewHealthcheckHealthContext parses the incoming request URL and body, performs validations and creates the context used by the health controller healthcheck action.
func (*HealthcheckHealthContext) OK ¶
func (ctx *HealthcheckHealthContext) OK(resp []byte) error
OK sends a HTTP response with status code 200.
type KeysController ¶
type KeysController interface { goa.Muxer List(*ListKeysContext) error }
KeysController is the controller interface for the Keys actions.
type ListKeysContext ¶
type ListKeysContext struct { context.Context *goa.ResponseData *goa.RequestData Payload ListKeysPayload }
ListKeysContext provides the keys list action context.
func NewListKeysContext ¶
func NewListKeysContext(ctx context.Context, r *http.Request, service *goa.Service) (*ListKeysContext, error)
NewListKeysContext parses the incoming request URL and body, performs validations and creates the context used by the keys controller list action.
func (*ListKeysContext) BadRequest ¶
func (ctx *ListKeysContext) BadRequest(r error) error
BadRequest sends a HTTP response with status code 400.
func (*ListKeysContext) GatewayTimeout ¶
func (ctx *ListKeysContext) GatewayTimeout(r error) error
GatewayTimeout sends a HTTP response with status code 504.
func (*ListKeysContext) InternalServerError ¶
func (ctx *ListKeysContext) InternalServerError() error
InternalServerError sends a HTTP response with status code 500.
func (*ListKeysContext) OK ¶
func (ctx *ListKeysContext) OK(r UserCollection) error
OK sends a HTTP response with status code 200.
type ListKeysPayload ¶
type ListKeysPayload []string
ListKeysPayload is the keys list action payload.
type User ¶
type User struct { // The list of the Github user's public SSH keys. Keys []*UserKey `form:"keys" json:"keys" xml:"keys"` // The username of the GitHub user. Username string `form:"username" json:"username" xml:"username"` }
Response Type for a GitHub User's list of public SSH Keys (default view)
Identifier: application/vnd.user+json; view=default
type UserCollection ¶
type UserCollection []*User
UserCollection is the media type for an array of User (default view)
Identifier: application/vnd.user+json; type=collection; view=default
func (UserCollection) Validate ¶
func (mt UserCollection) Validate() (err error)
Validate validates the UserCollection media type instance.