controller

package
v0.6.3 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2019 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApplicationController

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

ApplicationController to handle API related with application itself

func NewApplicationController

func NewApplicationController(conn *sql.DB) *ApplicationController

NewApplicationController return new instance of ApplicationController

func (*ApplicationController) Health

func (c *ApplicationController) Health(ctx echo.Context) error

Health end point for health check

func (*ApplicationController) Route added in v0.6.0

func (c *ApplicationController) Route(e *echo.Echo)

Route to define API Route

type BookController

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

BookController is controller to book entity

func NewBookController

func NewBookController(bookRepository repository.BookRepository) *BookController

NewBookController return new instance of book controller

func (*BookController) Create added in v0.3.0

func (c *BookController) Create(ctx echo.Context) (err error)

Create book

func (*BookController) Delete added in v0.3.0

func (c *BookController) Delete(ctx echo.Context) error

Delete book

func (*BookController) Get added in v0.3.0

func (c *BookController) Get(ctx echo.Context) error

Get book

func (*BookController) List added in v0.3.0

func (c *BookController) List(ctx echo.Context) error

List of book

func (*BookController) Route added in v0.6.0

func (c *BookController) Route(e *echo.Echo)

Route to define API Route

func (*BookController) Update added in v0.3.0

func (c *BookController) Update(ctx echo.Context) (err error)

Update book

Jump to

Keyboard shortcuts

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