Documentation
¶
Index ¶
- Variables
- type ColumnsAPIHandler
- type ContentAPIHandler
- func (handler *ContentAPIHandler) Create(request *http.Request, data map[string]string) (int, interface{})
- func (handler *ContentAPIHandler) Delete(request *http.Request, key string) (int, interface{})
- func (handler *ContentAPIHandler) Detail(request *http.Request, keyValue string) (int, interface{})
- func (handler *ContentAPIHandler) List(request *http.Request, param map[string]string) (int, interface{})
- func (handler *ContentAPIHandler) Update(request *http.Request, keyValue string, data map[string]string) (int, interface{})
- type HandlerBase
- type MenuAPIHandler
Constants ¶
This section is empty.
Variables ¶
View Source
var APIHandlerFactory apiHandlerFactory
ApiHandlerFactory use for create api handlers
Functions ¶
This section is empty.
Types ¶
type ColumnsAPIHandler ¶
type ColumnsAPIHandler struct {
HandlerBase
}
ColumnsAPIHandler use to handle API request
type ContentAPIHandler ¶
type ContentAPIHandler struct { TableName string HandlerBase }
ContentAPIHandler use to handle API request
func CreateContentHandler ¶
func CreateContentHandler(tableName string) *ContentAPIHandler
CreateContentHandler create Content API handler with table name
func (*ContentAPIHandler) Create ¶
func (handler *ContentAPIHandler) Create(request *http.Request, data map[string]string) (int, interface{})
Create create content
func (*ContentAPIHandler) Delete ¶
func (handler *ContentAPIHandler) Delete(request *http.Request, key string) (int, interface{})
Delete content action
func (*ContentAPIHandler) Detail ¶
func (handler *ContentAPIHandler) Detail(request *http.Request, keyValue string) (int, interface{})
type HandlerBase ¶
type HandlerBase interface { List(request *http.Request, param map[string]string) (int, interface{}) Detail(request *http.Request, key string) (int, interface{}) Create(request *http.Request, data map[string]string) (int, interface{}) Update(request *http.Request, keyValue string, data map[string]string) (int, interface{}) Delete(request *http.Request, key string) (int, interface{}) }
HandlerBase base class for all api handlers
type MenuAPIHandler ¶
type MenuAPIHandler struct {
HandlerBase
}
MenuAPIHandler use to handle API request
Click to show internal directories.
Click to hide internal directories.