Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FoodHandler ¶
type FoodHandler struct {
// contains filtered or unexported fields
}
FoodHandler handles initial HTTP request on /food/*
func (*FoodHandler) ServeHTTP ¶
func (fHandler *FoodHandler) ServeHTTP(res http.ResponseWriter, req *http.Request)
ServeHTTP responds to http request or routes to appropriate handler
type Handler ¶
type Handler struct { DB *database.Database FHandler *FoodHandler UHandler *UserHandler }
Handler handles initial HTTP request and forwards to appropriate handler.
func CreateHandler ¶
func CreateHandler() *Handler
CreateHandler creates a new Handler, connects to database, and initializes the (sub)handlers
type UserHandler ¶
type UserHandler struct {
// contains filtered or unexported fields
}
UserHandler routes and processes requests for /user/* Path
func (*UserHandler) ServeHTTP ¶
func (uHandler *UserHandler) ServeHTTP(res http.ResponseWriter, req *http.Request)
ServeHTTP is the first stop for the /user/ path request
Click to show internal directories.
Click to hide internal directories.