REST_api

package
v0.0.0-...-2b8ccbc Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateOrUpdateBook

func CreateOrUpdateBook(c *gin.Context, tempAction func(id uint, product product.Product) (product.Product, error))

func InitializeRoutes

func InitializeRoutes(router *gin.Engine, p *ProductAPI, u *UserAPI, f *FibonacciAPI) error

Types

type FibonacciAPI

type FibonacciAPI struct {
	FibonacciService fibonacci.FibonacciService
}

func ProvideFibonacciAPI

func ProvideFibonacciAPI(f fibonacci.FibonacciService) *FibonacciAPI

func (*FibonacciAPI) GetFibonacciAnswer

func (f *FibonacciAPI) GetFibonacciAnswer(c *gin.Context)

func (*FibonacciAPI) ShowGetFibonacciNumberPage

func (*FibonacciAPI) ShowGetFibonacciNumberPage(c *gin.Context)

type ProductAPI

type ProductAPI struct {
	ProductService product.ProductService
}

func ProvideProductAPI

func ProvideProductAPI(p product.ProductService) *ProductAPI

func (*ProductAPI) CreateBook

func (p *ProductAPI) CreateBook(c *gin.Context)

func (*ProductAPI) DeleteBook

func (p *ProductAPI) DeleteBook(c *gin.Context)

func (*ProductAPI) GetBook

func (p *ProductAPI) GetBook(c *gin.Context)

func (*ProductAPI) ShowBookCreatingPage

func (*ProductAPI) ShowBookCreatingPage(c *gin.Context)

func (*ProductAPI) ShowIndexPage

func (p *ProductAPI) ShowIndexPage(c *gin.Context)

func (*ProductAPI) UpdateBook

func (p *ProductAPI) UpdateBook(c *gin.Context)

type UserAPI

type UserAPI struct {
	UserService user.UserService
}

func ProvideUserAPI

func ProvideUserAPI(p user.UserService) *UserAPI

func (*UserAPI) Logout

func (*UserAPI) Logout(c *gin.Context)

func (*UserAPI) PerformLogin

func (u *UserAPI) PerformLogin(c *gin.Context)

func (*UserAPI) Register

func (u *UserAPI) Register(c *gin.Context)

func (*UserAPI) ShowLoginPage

func (*UserAPI) ShowLoginPage(c *gin.Context)

func (*UserAPI) ShowRegistrationPage

func (*UserAPI) ShowRegistrationPage(c *gin.Context)

Jump to

Keyboard shortcuts

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