Documentation ¶
Index ¶
- func NewHTTPError(code int, msg string) httpError
- type AssetsController
- type Controller
- type HTTPError
- type IndexController
- type MuxServer
- type ReadyController
- type TweetController
- func (c *TweetController) Get(w http.ResponseWriter, r *http.Request)
- func (c *TweetController) Handle(w http.ResponseWriter, r *http.Request)
- func (c *TweetController) Name() string
- func (c *TweetController) Post(w http.ResponseWriter, r *http.Request)
- func (c *TweetController) RegisterHandlers(server MuxServer)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewHTTPError ¶
Types ¶
type AssetsController ¶
type AssetsController struct { }
func NewAssetsController ¶
func NewAssetsController() *AssetsController
func (*AssetsController) Name ¶
func (c *AssetsController) Name() string
func (*AssetsController) RegisterHandlers ¶
func (c *AssetsController) RegisterHandlers(server MuxServer)
type Controller ¶
type IndexController ¶
type IndexController struct {
// contains filtered or unexported fields
}
func NewIndexController ¶
func NewIndexController(repo service.TweetRepo, instanceName string) *IndexController
func (*IndexController) AvatarURL ¶
func (c *IndexController) AvatarURL(handle string) string
func (*IndexController) Handle ¶
func (c *IndexController) Handle(w http.ResponseWriter, r *http.Request)
func (*IndexController) Name ¶
func (c *IndexController) Name() string
func (*IndexController) RegisterHandlers ¶
func (c *IndexController) RegisterHandlers(server MuxServer)
type ReadyController ¶
type ReadyController struct {
// contains filtered or unexported fields
}
func NewReadyController ¶
func NewReadyController(svc service.Service, instanceName string) *ReadyController
func (*ReadyController) Handle ¶
func (c *ReadyController) Handle(w http.ResponseWriter, r *http.Request)
func (*ReadyController) Name ¶
func (c *ReadyController) Name() string
func (*ReadyController) RegisterHandlers ¶
func (c *ReadyController) RegisterHandlers(server MuxServer)
type TweetController ¶
type TweetController struct {
// contains filtered or unexported fields
}
func NewTweetController ¶
func NewTweetController(repo service.TweetRepo) *TweetController
func (*TweetController) Get ¶
func (c *TweetController) Get(w http.ResponseWriter, r *http.Request)
func (*TweetController) Handle ¶
func (c *TweetController) Handle(w http.ResponseWriter, r *http.Request)
func (*TweetController) Name ¶
func (c *TweetController) Name() string
func (*TweetController) Post ¶
func (c *TweetController) Post(w http.ResponseWriter, r *http.Request)
func (*TweetController) RegisterHandlers ¶
func (c *TweetController) RegisterHandlers(server MuxServer)
Click to show internal directories.
Click to hide internal directories.