Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIResponse ¶
type APIResponse struct {
// code
Code int64 `json:"code,omitempty"`
// a (key, value) map.
Details interface{} `json:"details,omitempty"`
// message
Message string `json:"message,omitempty"`
}
APIResponse Api response
swagger:model ApiResponse
func (*APIResponse) ContextValidate ¶
ContextValidate validates this Api response based on context it is used
func (*APIResponse) MarshalBinary ¶
func (m *APIResponse) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*APIResponse) UnmarshalBinary ¶
func (m *APIResponse) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type Author ¶
type Author struct {
// books
Books []*Book `json:"books"`
// id
ID int64 `json:"id,omitempty"`
// name
// Required: true
Name *string `json:"name"`
}
Author author
swagger:model Author
func (*Author) ContextValidate ¶
ContextValidate validate this author based on the context it is used
func (*Author) MarshalBinary ¶
MarshalBinary interface implementation
func (*Author) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type Book ¶
type Book struct {
// author ID
AuthorID int64 `json:"authorID,omitempty"`
// genre
// Required: true
Genre *string `json:"genre"`
// id
ID int64 `json:"id,omitempty"`
// isbn
// Required: true
Isbn *string `json:"isbn"`
// name
// Required: true
Name *string `json:"name"`
// page number
// Required: true
PageNumber *int64 `json:"pageNumber"`
// release date
// Required: true
// Format: date
ReleaseDate *strfmt.Date `json:"releaseDate"`
}
Book book
swagger:model Book
func (*Book) ContextValidate ¶
ContextValidate validates this book based on context it is used
func (*Book) MarshalBinary ¶
MarshalBinary interface implementation
func (*Book) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type Login ¶
type Login struct {
// email
// Required: true
Email *string `json:"email"`
// password
// Required: true
Password *string `json:"password"`
}
Login login
swagger:model Login
func (*Login) ContextValidate ¶
ContextValidate validates this login based on context it is used
func (*Login) MarshalBinary ¶
MarshalBinary interface implementation
func (*Login) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type User ¶
type User struct {
// email
Email string `json:"email,omitempty"`
// first name
FirstName string `json:"firstName,omitempty"`
// id
ID int64 `json:"id,omitempty"`
// is admin
IsAdmin bool `json:"isAdmin,omitempty"`
// last name
LastName string `json:"lastName,omitempty"`
// password
Password string `json:"password,omitempty"`
// phone
Phone string `json:"phone,omitempty"`
// username
Username string `json:"username,omitempty"`
}
User user
swagger:model User
func (*User) ContextValidate ¶
ContextValidate validates this user based on context it is used
func (*User) MarshalBinary ¶
MarshalBinary interface implementation
func (*User) UnmarshalBinary ¶
UnmarshalBinary interface implementation