V2
This commit is contained in:
@ -16,6 +16,14 @@ import (
|
||||
|
||||
|
||||
|
||||
// InboxApiRouter defines the required methods for binding the api requests to a responses for the InboxApi
|
||||
// The InboxApiRouter implementation should parse necessary information from the http request,
|
||||
// pass the data to a InboxApiServicer to perform the required actions, then write the service results to the http response.
|
||||
type InboxApiRouter interface {
|
||||
AddInboxItem(http.ResponseWriter, *http.Request)
|
||||
DeleteInboxItem(http.ResponseWriter, *http.Request)
|
||||
GetInboxItems(http.ResponseWriter, *http.Request)
|
||||
}
|
||||
// JournalApiRouter defines the required methods for binding the api requests to a responses for the JournalApi
|
||||
// The JournalApiRouter implementation should parse necessary information from the http request,
|
||||
// pass the data to a JournalApiServicer to perform the required actions, then write the service results to the http response.
|
||||
@ -35,6 +43,25 @@ type PlanApiRouter interface {
|
||||
SavePlanForMonth(http.ResponseWriter, *http.Request)
|
||||
SavePlanForWeek(http.ResponseWriter, *http.Request)
|
||||
}
|
||||
// TrackingApiRouter defines the required methods for binding the api requests to a responses for the TrackingApi
|
||||
// The TrackingApiRouter implementation should parse necessary information from the http request,
|
||||
// pass the data to a TrackingApiServicer to perform the required actions, then write the service results to the http response.
|
||||
type TrackingApiRouter interface {
|
||||
GetTrackingCategories(http.ResponseWriter, *http.Request)
|
||||
GetTrackingEntryForDate(http.ResponseWriter, *http.Request)
|
||||
WriteTrackingEntry(http.ResponseWriter, *http.Request)
|
||||
}
|
||||
|
||||
|
||||
// InboxApiServicer defines the api actions for the InboxApi service
|
||||
// This interface intended to stay up to date with the openapi yaml used to generate it,
|
||||
// while the service implementation can be ignored with the .openapi-generator-ignore file
|
||||
// and updated with the logic required for the API.
|
||||
type InboxApiServicer interface {
|
||||
AddInboxItem(context.Context, InboxItem) (ImplResponse, error)
|
||||
DeleteInboxItem(context.Context, int32) (ImplResponse, error)
|
||||
GetInboxItems(context.Context) (ImplResponse, error)
|
||||
}
|
||||
|
||||
|
||||
// JournalApiServicer defines the api actions for the JournalApi service
|
||||
@ -60,3 +87,14 @@ type PlanApiServicer interface {
|
||||
SavePlanForMonth(context.Context, PlanMonth) (ImplResponse, error)
|
||||
SavePlanForWeek(context.Context, PlanWeek) (ImplResponse, error)
|
||||
}
|
||||
|
||||
|
||||
// TrackingApiServicer defines the api actions for the TrackingApi service
|
||||
// This interface intended to stay up to date with the openapi yaml used to generate it,
|
||||
// while the service implementation can be ignored with the .openapi-generator-ignore file
|
||||
// and updated with the logic required for the API.
|
||||
type TrackingApiServicer interface {
|
||||
GetTrackingCategories(context.Context) (ImplResponse, error)
|
||||
GetTrackingEntryForDate(context.Context, string) (ImplResponse, error)
|
||||
WriteTrackingEntry(context.Context, TrackingEntry) (ImplResponse, error)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user