Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ErrInternalServerError ¶
func ErrInvalidRequest ¶
Types ¶
type ErrResponse ¶
type ErrResponse struct { Err error `json:"-"` // low-level runtime error HTTPStatusCode int `json:"-"` // http response status code StatusText string `json:"status"` // user-level status message AppCode int64 `json:"code,omitempty"` // application-specific error code ErrorText string `json:"error,omitempty"` // application-level error message, for debugging }
func (*ErrResponse) Render ¶
func (e *ErrResponse) Render(w http.ResponseWriter, r *http.Request) error
type OrderItemResponse ¶
type OrderItemResponse struct {
*dto.OrderItemResponseDto
}
func NewOrderItemResponse ¶
func NewOrderItemResponse(product *dto.OrderItemResponseDto) *OrderItemResponse
func (*OrderItemResponse) Render ¶
func (pr *OrderItemResponse) Render(w http.ResponseWriter, r *http.Request) error
type OrderResponse ¶
type OrderResponse struct {
*dto.OrderResponseDto
}
func NewOrderResponse ¶
func NewOrderResponse(product *dto.OrderResponseDto) *OrderResponse
func (*OrderResponse) Render ¶
func (pr *OrderResponse) Render(w http.ResponseWriter, r *http.Request) error
type OrdersResponse ¶
type OrdersResponse struct {
Items []*dto.OrderResponseDto
}
func NewOrdersResponse ¶
func NewOrdersResponse(products []*dto.OrderResponseDto) *OrdersResponse
func (*OrdersResponse) Render ¶
func (pr *OrdersResponse) Render(w http.ResponseWriter, r *http.Request) error
Click to show internal directories.
Click to hide internal directories.