controllers

package
v0.0.0-...-d98ba24 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 16, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Controller

type Controller struct {
	// contains filtered or unexported fields
}

type MainController

type MainController struct {
	Controller
}

func NewMainController

func NewMainController(connection db.DbConnection) *MainController

func (*MainController) MainUrl

func (c *MainController) MainUrl(w http.ResponseWriter, r *http.Request)

type ResponseBody

type ResponseBody struct {
	Short_url string `json:"short_url"`
}

type UrlController

type UrlController struct {
	Controller
}

func NewUrlController

func NewUrlController(connection db.DbConnection) *UrlController

func (*UrlController) MakeUrl

func (c *UrlController) MakeUrl(w http.ResponseWriter, r *http.Request)

func (*UrlController) RedirectShortenUrl

func (c *UrlController) RedirectShortenUrl(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL