Documentation ¶
Index ¶
- func ErrAlreadySet(field string, value interface{}) error
- func ErrNotExported(field string) error
- func ErrNotPositive(field string) error
- type Criterion
- func (c *Criterion) Contains(value interface{}) *Query
- func (c *Criterion) ContainsAll(values ...interface{}) *Query
- func (c *Criterion) ContainsAny(values ...interface{}) *Query
- func (c *Criterion) Eq(value interface{}) *Query
- func (c *Criterion) Ge(value interface{}) *Query
- func (c *Criterion) Gt(value interface{}) *Query
- func (c *Criterion) HasKey(value interface{}) *Query
- func (c *Criterion) HasPrefix(prefix string) *Query
- func (c *Criterion) HasSuffix(suffix string) *Query
- func (c *Criterion) In(values ...interface{}) *Query
- func (c *Criterion) IsNil() *Query
- func (c *Criterion) Le(value interface{}) *Query
- func (c *Criterion) Lt(value interface{}) *Query
- func (c *Criterion) Match(expression *regexp.Regexp) *Query
- func (c *Criterion) Ne(value interface{}) *Query
- type Query
- type Store
- type Transaction
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ErrAlreadySet ¶
func ErrNotExported ¶
func ErrNotPositive ¶
Types ¶
type Criterion ¶
type Criterion struct {
// contains filtered or unexported fields
}
Criterion is an operator and a value that a given field needs to match on
func Where ¶
Where starts a Query for specifying the criteria that an object needs to match to be returned in a Find result
func (*Criterion) Contains ¶
Contains tests if the current field is a slice that contains the passed in value
func (*Criterion) ContainsAll ¶
ContainsAll tests if the current field is a slice that contains all of the passed in values
func (*Criterion) ContainsAny ¶
ContainsAny tests if the current field is a slice that contains any of the passed in values
func (*Criterion) Ge ¶
Ge tests if the current field is Greater Than or Equal To the passed in value
func (*Criterion) HasKey ¶
HasKey tests if the current field has a map key matching the passed in value
type Query ¶
type Query struct {
// contains filtered or unexported fields
}
Query is a chained collection of criteria of which an object needs to match to be returned. An Empty query matches against all records.
func (*Query) Limit ¶
Limit sets the maximum number of records that can be returned by a query. Setting Limit multiple times or to a negative value will panic.
type Transaction ¶
type Transaction interface{}