Documentation ¶
Index ¶
- Constants
- func HTTPHandler(f HTTPHandlerFunc) http.HandlerFunc
- func JSONHandler(f RestHandlerFunc) http.HandlerFunc
- func NewMux(basePath string, client *gorp.Client, kvStore store.KVStore) http.Handler
- func ReadJSON(r io.Reader, s interface{}) error
- type HTTPHandlerFunc
- type RestHandlerFunc
- type StatusErr
Constants ¶
View Source
const LogRequestBinaryPart = "binary_part"
Save Log Request binary part
View Source
const LogRequestJsonPart = "json_request_part"
Save Log Request part with json data
Variables ¶
This section is empty.
Functions ¶
func HTTPHandler ¶
func HTTPHandler(f HTTPHandlerFunc) http.HandlerFunc
HTTPHandler handles HTTP requests
func JSONHandler ¶
func JSONHandler(f RestHandlerFunc) http.HandlerFunc
JSONHandler is a handler for JSON response content type handlers
Types ¶
type HTTPHandlerFunc ¶
type HTTPHandlerFunc func(w http.ResponseWriter, rq *http.Request) error
HTTPHandlerFunc is a handler func for JSON/REST handlers
type RestHandlerFunc ¶
RestHandlerFunc handles REST requests
type StatusErr ¶
type StatusErr struct {
// contains filtered or unexported fields
}
StatusErr describes HTTP status error
func NewStatusErr ¶
NewStatusErr creates new status error
func (*StatusErr) StackTrace ¶
func (se *StatusErr) StackTrace() errors.StackTrace
StackTrace returns stack trace of an error
Click to show internal directories.
Click to hide internal directories.