Documentation
¶
Index ¶
- func MountSwaggerController(service *goa.Service, ctrl SwaggerController)
- func MountUserProfileController(service *goa.Service, ctrl UserProfileController)
- type FilterPayload
- type FilterProperty
- type FindUserProfileUserProfileContext
- type GetMyProfileUserProfileContext
- type GetUserProfileUserProfileContext
- type OrderSpec
- type SwaggerController
- type UpdateMyProfileUserProfileContext
- type UpdateUserProfileUserProfileContext
- type UserProfile
- type UserProfileController
- type UserProfilePage
- type UserProfilePayload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MountSwaggerController ¶
func MountSwaggerController(service *goa.Service, ctrl SwaggerController)
MountSwaggerController "mounts" a Swagger resource controller on the given service.
func MountUserProfileController ¶
func MountUserProfileController(service *goa.Service, ctrl UserProfileController)
MountUserProfileController "mounts" a UserProfile resource controller on the given service.
Types ¶
type FilterPayload ¶ added in v1.1.2
type FilterPayload struct {
// Organizations filter.
Filter []*FilterProperty `form:"filter,omitempty" json:"filter,omitempty" yaml:"filter,omitempty" xml:"filter,omitempty"`
// Page number (1-based).
Page int `form:"page" json:"page" yaml:"page" xml:"page"`
// Items per page.
PageSize int `form:"pageSize" json:"pageSize" yaml:"pageSize" xml:"pageSize"`
// Sort specification.
Sort *OrderSpec `form:"sort,omitempty" json:"sort,omitempty" yaml:"sort,omitempty" xml:"sort,omitempty"`
}
FilterPayload user type.
func (*FilterPayload) Validate ¶ added in v1.1.2
func (ut *FilterPayload) Validate() (err error)
Validate validates the FilterPayload type instance.
type FilterProperty ¶ added in v1.1.2
type FilterProperty struct {
// Property name
Property string `form:"property" json:"property" yaml:"property" xml:"property"`
// Property value to match
Value string `form:"value" json:"value" yaml:"value" xml:"value"`
}
FilterProperty user type.
func (*FilterProperty) Validate ¶ added in v1.1.2
func (ut *FilterProperty) Validate() (err error)
Validate validates the FilterProperty type instance.
type FindUserProfileUserProfileContext ¶ added in v1.1.2
type FindUserProfileUserProfileContext struct {
context.Context
*goa.ResponseData
*goa.RequestData
Payload *FilterPayload
}
FindUserProfileUserProfileContext provides the userProfile FindUserProfile action context.
func NewFindUserProfileUserProfileContext ¶ added in v1.1.2
func NewFindUserProfileUserProfileContext(ctx context.Context, r *http.Request, service *goa.Service) (*FindUserProfileUserProfileContext, error)
NewFindUserProfileUserProfileContext parses the incoming request URL and body, performs validations and creates the context used by the userProfile controller FindUserProfile action.
func (*FindUserProfileUserProfileContext) BadRequest ¶ added in v1.1.2
func (ctx *FindUserProfileUserProfileContext) BadRequest(r error) error
BadRequest sends a HTTP response with status code 400.
func (*FindUserProfileUserProfileContext) InternalServerError ¶ added in v1.1.2
func (ctx *FindUserProfileUserProfileContext) InternalServerError(r error) error
InternalServerError sends a HTTP response with status code 500.
func (*FindUserProfileUserProfileContext) OK ¶ added in v1.1.2
func (ctx *FindUserProfileUserProfileContext) OK(r *UserProfilePage) error
OK sends a HTTP response with status code 200.
type GetMyProfileUserProfileContext ¶
type GetMyProfileUserProfileContext struct {
context.Context
*goa.ResponseData
*goa.RequestData
}
GetMyProfileUserProfileContext provides the userProfile GetMyProfile action context.
func NewGetMyProfileUserProfileContext ¶
func NewGetMyProfileUserProfileContext(ctx context.Context, r *http.Request, service *goa.Service) (*GetMyProfileUserProfileContext, error)
NewGetMyProfileUserProfileContext parses the incoming request URL and body, performs validations and creates the context used by the userProfile controller GetMyProfile action.
func (*GetMyProfileUserProfileContext) BadRequest ¶
func (ctx *GetMyProfileUserProfileContext) BadRequest(r error) error
BadRequest sends a HTTP response with status code 400.
func (*GetMyProfileUserProfileContext) InternalServerError ¶
func (ctx *GetMyProfileUserProfileContext) InternalServerError(r error) error
InternalServerError sends a HTTP response with status code 500.
func (*GetMyProfileUserProfileContext) NotFound ¶
func (ctx *GetMyProfileUserProfileContext) NotFound(r error) error
NotFound sends a HTTP response with status code 404.
func (*GetMyProfileUserProfileContext) OK ¶
func (ctx *GetMyProfileUserProfileContext) OK(r *UserProfile) error
OK sends a HTTP response with status code 200.
type GetUserProfileUserProfileContext ¶
type GetUserProfileUserProfileContext struct {
context.Context
*goa.ResponseData
*goa.RequestData
UserID string
}
GetUserProfileUserProfileContext provides the userProfile GetUserProfile action context.
func NewGetUserProfileUserProfileContext ¶
func NewGetUserProfileUserProfileContext(ctx context.Context, r *http.Request, service *goa.Service) (*GetUserProfileUserProfileContext, error)
NewGetUserProfileUserProfileContext parses the incoming request URL and body, performs validations and creates the context used by the userProfile controller GetUserProfile action.
func (*GetUserProfileUserProfileContext) BadRequest ¶
func (ctx *GetUserProfileUserProfileContext) BadRequest(r error) error
BadRequest sends a HTTP response with status code 400.
func (*GetUserProfileUserProfileContext) InternalServerError ¶
func (ctx *GetUserProfileUserProfileContext) InternalServerError(r error) error
InternalServerError sends a HTTP response with status code 500.
func (*GetUserProfileUserProfileContext) NotFound ¶
func (ctx *GetUserProfileUserProfileContext) NotFound(r error) error
NotFound sends a HTTP response with status code 404.
func (*GetUserProfileUserProfileContext) OK ¶
func (ctx *GetUserProfileUserProfileContext) OK(r *UserProfile) error
OK sends a HTTP response with status code 200.
type OrderSpec ¶ added in v1.1.2
type OrderSpec struct {
// Sort order. Can be 'asc' or 'desc'.
Direction string `form:"direction" json:"direction" yaml:"direction" xml:"direction"`
// Sort by property
Property string `form:"property" json:"property" yaml:"property" xml:"property"`
}
OrderSpec user type.
type SwaggerController ¶
type SwaggerController interface {
goa.Muxer
goa.FileServer
}
SwaggerController is the controller interface for the Swagger actions.
type UpdateMyProfileUserProfileContext ¶
type UpdateMyProfileUserProfileContext struct {
context.Context
*goa.ResponseData
*goa.RequestData
Payload *UserProfilePayload
}
UpdateMyProfileUserProfileContext provides the userProfile UpdateMyProfile action context.
func NewUpdateMyProfileUserProfileContext ¶
func NewUpdateMyProfileUserProfileContext(ctx context.Context, r *http.Request, service *goa.Service) (*UpdateMyProfileUserProfileContext, error)
NewUpdateMyProfileUserProfileContext parses the incoming request URL and body, performs validations and creates the context used by the userProfile controller UpdateMyProfile action.
func (*UpdateMyProfileUserProfileContext) BadRequest ¶
func (ctx *UpdateMyProfileUserProfileContext) BadRequest(r error) error
BadRequest sends a HTTP response with status code 400.
func (*UpdateMyProfileUserProfileContext) InternalServerError ¶
func (ctx *UpdateMyProfileUserProfileContext) InternalServerError(r error) error
InternalServerError sends a HTTP response with status code 500.
func (*UpdateMyProfileUserProfileContext) NotFound ¶
func (ctx *UpdateMyProfileUserProfileContext) NotFound(r error) error
NotFound sends a HTTP response with status code 404.
func (*UpdateMyProfileUserProfileContext) OK ¶
func (ctx *UpdateMyProfileUserProfileContext) OK(r *UserProfile) error
OK sends a HTTP response with status code 200.
type UpdateUserProfileUserProfileContext ¶
type UpdateUserProfileUserProfileContext struct {
context.Context
*goa.ResponseData
*goa.RequestData
UserID string
Payload *UserProfilePayload
}
UpdateUserProfileUserProfileContext provides the userProfile UpdateUserProfile action context.
func NewUpdateUserProfileUserProfileContext ¶
func NewUpdateUserProfileUserProfileContext(ctx context.Context, r *http.Request, service *goa.Service) (*UpdateUserProfileUserProfileContext, error)
NewUpdateUserProfileUserProfileContext parses the incoming request URL and body, performs validations and creates the context used by the userProfile controller UpdateUserProfile action.
func (*UpdateUserProfileUserProfileContext) BadRequest ¶
func (ctx *UpdateUserProfileUserProfileContext) BadRequest(r error) error
BadRequest sends a HTTP response with status code 400.
func (*UpdateUserProfileUserProfileContext) InternalServerError ¶
func (ctx *UpdateUserProfileUserProfileContext) InternalServerError(r error) error
InternalServerError sends a HTTP response with status code 500.
func (*UpdateUserProfileUserProfileContext) OK ¶
func (ctx *UpdateUserProfileUserProfileContext) OK(r *UserProfile) error
OK sends a HTTP response with status code 200.
type UserProfile ¶
type UserProfile struct {
// Company name
Company *string `form:"company,omitempty" json:"company,omitempty" yaml:"company,omitempty" xml:"company,omitempty"`
// Company registration number
CompanyRegistrationNumber *string `` /* 170-byte string literal not displayed */
// User profile created timestamp
CreatedOn int `form:"createdOn" json:"createdOn" yaml:"createdOn" xml:"createdOn"`
// Email of user
Email *string `form:"email,omitempty" json:"email,omitempty" yaml:"email,omitempty" xml:"email,omitempty"`
// Full name of the user
FullName *string `form:"fullName,omitempty" json:"fullName,omitempty" yaml:"fullName,omitempty" xml:"fullName,omitempty"`
// Tax number
TaxNumber *string `form:"taxNumber,omitempty" json:"taxNumber,omitempty" yaml:"taxNumber,omitempty" xml:"taxNumber,omitempty"`
// Unique user ID
UserID string `form:"userId" json:"userId" yaml:"userId" xml:"userId"`
}
userProfile media type (default view)
Identifier: application/microkubes.user-profile+json; view=default
func (*UserProfile) Validate ¶
func (mt *UserProfile) Validate() (err error)
Validate validates the UserProfile media type instance.
type UserProfileController ¶
type UserProfileController interface {
goa.Muxer
FindUserProfile(*FindUserProfileUserProfileContext) error
GetMyProfile(*GetMyProfileUserProfileContext) error
GetUserProfile(*GetUserProfileUserProfileContext) error
UpdateMyProfile(*UpdateMyProfileUserProfileContext) error
UpdateUserProfile(*UpdateUserProfileUserProfileContext) error
}
UserProfileController is the controller interface for the UserProfile actions.
type UserProfilePage ¶ added in v1.1.2
type UserProfilePage struct {
// User profile list
Items []*UserProfile `form:"items,omitempty" json:"items,omitempty" yaml:"items,omitempty" xml:"items,omitempty"`
// Page number (1-based).
Page *int `form:"page,omitempty" json:"page,omitempty" yaml:"page,omitempty" xml:"page,omitempty"`
// Items per page.
PageSize *int `form:"pageSize,omitempty" json:"pageSize,omitempty" yaml:"pageSize,omitempty" xml:"pageSize,omitempty"`
}
UserProfilePage media type (default view)
Identifier: application/microkubes.user-profile-page+json; view=default
func (*UserProfilePage) Validate ¶ added in v1.1.2
func (mt *UserProfilePage) Validate() (err error)
Validate validates the UserProfilePage media type instance.
type UserProfilePayload ¶
type UserProfilePayload struct {
// Company name
Company *string `form:"company,omitempty" json:"company,omitempty" yaml:"company,omitempty" xml:"company,omitempty"`
// Company registration number
CompanyRegistrationNumber *string `` /* 170-byte string literal not displayed */
// Email of user
Email string `form:"email" json:"email" yaml:"email" xml:"email"`
// Full name of the user
FullName string `form:"fullName" json:"fullName" yaml:"fullName" xml:"fullName"`
// Tax number
TaxNumber *string `form:"taxNumber,omitempty" json:"taxNumber,omitempty" yaml:"taxNumber,omitempty" xml:"taxNumber,omitempty"`
}
UserProfile data
func (*UserProfilePayload) Validate ¶
func (ut *UserProfilePayload) Validate() (err error)
Validate validates the UserProfilePayload type instance.