Documentation ¶
Index ¶
Constants ¶
View Source
const ( ComparatorEq Comparator = 0 ComparatorGt Comparator = 1 ComparatorGte Comparator = 2 ComparatorLt Comparator = 3 ComparatorLte Comparator = 4 ComparatorIn Comparator = 5 LogicOperatorAnd LogicOperator = 0 LogicOperatorOr LogicOperator = 1 )
Variables ¶
View Source
var (
ErrResolveRepo = errors.New("resolve repository")
)
View Source
var ( OrderValue = map[Order]string{ OrderAsc: "ASC", OrderDesc: "DESC", } )
Functions ¶
func DecodeCursor ¶
Types ¶
type Comparator ¶
type Comparator int
func (Comparator) String ¶
func (c Comparator) String() string
type CompiledQuery ¶
type Definition ¶
type Filtering ¶
type Filtering struct { Fields []FilteringField Operator LogicOperator }
type FilteringField ¶
type FilteringField struct { Name string `json:"name"` Value interface{} `json:"value"` Comparator Comparator `json:"comparator"` }
type LogicOperator ¶
type LogicOperator int
func (LogicOperator) String ¶
func (l LogicOperator) String() string
type Pagination ¶
func (*Pagination) String ¶
func (p *Pagination) String() string
type Query ¶
type Query struct { Pagination Pagination `json:"pagination"` Sorting Sorting `json:"sorting"` Filtering Filtering `json:"filtering"` }
type QueryResult ¶
type Sorting ¶
type Sorting struct {
Fields []*SortingField `json:"columns"`
}
type SortingField ¶
Click to show internal directories.
Click to hide internal directories.