Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Entity ¶
type Entity[T any] struct { // contains filtered or unexported fields }
func (Entity[T]) ToResponse ¶
type Response ¶
type Response[T any] struct { Success bool `json:"success"` Data T `json:"data,omitempty"` Page *int `json:"page,omitempty"` Size *int `json:"size,omitempty"` TotalElements *int `json:"totalElements,omitempty"` TotalPages *int `json:"totalPages,omitempty"` // Error fields Message string `json:"message,omitempty"` ValidationErrors []validation.FieldError `json:"validationErrors,omitempty"` }
func Error ¶
func Error(msg string, fieldErrs ...validation.FieldError) Response[any]
Click to show internal directories.
Click to hide internal directories.