Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler defines a handler struct
func NewHandler ¶
func NewHandler(dbSvc services.IdbService, bSvc services.Ibooks) *Handler
NewHandler returns a new instance of Handler
func (*Handler) GetBook ¶
GetBook resolves GET /{userID}/book/{isbn}, retreives details of a book from database
func (*Handler) GetNewBook ¶
GetNewBook resolves GET /book/:isbn, retreives details of a book from providers.
func (*Handler) ListBook ¶
ListBook resolves GET /{userID}/books, retreives the list of books related to the userID
func (*Handler) UpsertBook ¶
UpsertBook resolves POST /{userID}/book, updates a database book record if record is found, creates a new record if no record found.
Click to show internal directories.
Click to hide internal directories.