Documentation ¶
Index ¶
- type BudgetResource
- func (r *BudgetResource) Get(context smolder.APIContext, request *restful.Request, ...)
- func (r *BudgetResource) GetAuthRequired() bool
- func (r *BudgetResource) GetDoc() string
- func (r *BudgetResource) GetParams() []*restful.Parameter
- func (r *BudgetResource) Register(container *restful.Container, config smolder.APIConfig, ...)
- func (r *BudgetResource) Returns() interface{}
- type BudgetResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BudgetResource ¶
BudgetResource is the resource responsible for /budgets
func (*BudgetResource) Get ¶
func (r *BudgetResource) Get(context smolder.APIContext, request *restful.Request, response *restful.Response, params map[string][]string)
Get sends out items matching the query parameters
func (*BudgetResource) GetAuthRequired ¶
func (r *BudgetResource) GetAuthRequired() bool
GetAuthRequired returns true because all requests need authentication
func (*BudgetResource) GetDoc ¶
func (r *BudgetResource) GetDoc() string
GetDoc returns the description of this API endpoint
func (*BudgetResource) GetParams ¶
func (r *BudgetResource) GetParams() []*restful.Parameter
GetParams returns the parameters supported by this API endpoint
func (*BudgetResource) Register ¶
func (r *BudgetResource) Register(container *restful.Container, config smolder.APIConfig, context smolder.APIContextFactory)
Register this resource with the container to setup all the routes
func (*BudgetResource) Returns ¶
func (r *BudgetResource) Returns() interface{}
Returns returns the model that will be returned
type BudgetResponse ¶
type BudgetResponse struct { smolder.Response Budgets []budgetInfoResponse `json:"budgets,omitempty"` }
BudgetResponse is the common response to 'budget' requests
func (*BudgetResponse) EmptyResponse ¶
func (r *BudgetResponse) EmptyResponse() interface{}
EmptyResponse returns an empty API response for this endpoint if there's no data to respond with
func (*BudgetResponse) Init ¶
func (r *BudgetResponse) Init(context smolder.APIContext)
Init a new response
Click to show internal directories.
Click to hide internal directories.