Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
type Handler struct {
gonethttphandler.RequestsHandler
gonethttphandler.ResponsesHandler
}
Handler is the handler implementation for handling JSON requests and responses
func NewHandler ¶
func NewHandler( mode *goflagsmode.Flag, rawErrorHandler gonethttphandler.RawErrorHandler, ) (*Handler, error)
NewHandler creates a new JSON handler
Parameters:
- mode: the flag mode
- rawErrorHandler: the raw error handler
Returns:
- *Handler: the created JSON handler
- error: the error if any
type StreamHandler ¶
type StreamHandler struct {
gonethttphandler.RequestsHandler
gonethttphandler.ResponsesHandler
}
StreamHandler is the handler implementation for handling JSON stream requests and responses
func NewStreamHandler ¶
func NewStreamHandler( mode *goflagsmode.Flag, rawErrorhandler gonethttphandler.RawErrorHandler, ) ( *StreamHandler, error, )
NewStreamHandler creates a new JSON handler
Parameters:
- mode: the flag mode
- rawErrorhandler: the raw error handler
Returns:
- *StreamHandler: the created JSON handler
- error: the error if any
Click to show internal directories.
Click to hide internal directories.