moviectl

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddMovieRequest

type AddMovieRequest struct {
	Title    string `json:"Title"`
	Year     int    `json:"Year"`
	Rated    string `json:"Rated"`
	Released string `json:"ReleaseDate"`
	RunTime  int    `json:"RunTime"`
	Director string `json:"Director"`
	Writer   string `json:"Writer"`
}

AddMovieRequest is the request struct

type MovieController added in v0.12.0

type MovieController struct {
	App *app.Application
}

MovieController is used as the base controller for the Movie logic

func ProvideMovieController added in v0.12.0

func ProvideMovieController(app *app.Application) *MovieController

ProvideMovieController initializes MovieController

func (*MovieController) Add added in v0.12.0

Add adds a movie to the catalog.

func (*MovieController) FindByID added in v0.12.0

func (ctl *MovieController) FindByID(ctx context.Context, id string) (*MovieResponse, error)

FindByID finds a movie given its' unique ID

type MovieResponse added in v0.12.0

type MovieResponse struct {
	ExtlID          string `json:"ExtlID"`
	Title           string `json:"Title"`
	Year            int    `json:"Year"`
	Rated           string `json:"Rated"`
	Released        string `json:"ReleaseDate"`
	RunTime         int    `json:"RunTime"`
	Director        string `json:"Director"`
	Writer          string `json:"Writer"`
	CreateTimestamp string `json:"CreateTimestamp"`
}

MovieResponse is the response struct

Jump to

Keyboard shortcuts

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