Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRouxinolController ¶
func NewRouxinolController(router *mux.Router, postRepo post.Repository, userRepo user.Repository)
NewRouxinolController provides a controller
Types ¶
type RouxinolController ¶
type RouxinolController struct {
// contains filtered or unexported fields
}
RouxinolController encapsulates rouxinol's repositories
func (*RouxinolController) GetPosts ¶
func (rx *RouxinolController) GetPosts(w http.ResponseWriter, r *http.Request)
GetPosts retrieves all posts by user id
func (*RouxinolController) NewPost ¶
func (rx *RouxinolController) NewPost(w http.ResponseWriter, r *http.Request)
NewPost creates a new post
Click to show internal directories.
Click to hide internal directories.