Documentation ¶
Index ¶
- type Cache
- func (a *Cache) AddValues(ctx context.Context, entry *cache.Entry, values []interface{}) error
- func (a *Cache) AsSource(ctx context.Context, entry *cache.Entry) (cache.Source, error)
- func (a *Cache) AssignRows(entry *cache.Entry, rows *sql.Rows) error
- func (a *Cache) Close(ctx context.Context, entry *cache.Entry) error
- func (a *Cache) Delete(ctx context.Context, entry *cache.Entry) error
- func (a *Cache) Get(ctx context.Context, SQL string, args []interface{}, options ...interface{}) (*cache.Entry, error)
- func (a *Cache) IndexBy(ctx context.Context, db *sql.DB, column, SQL string, args []interface{}) (int, error)
- func (a *Cache) Rollback(ctx context.Context, entry *cache.Entry) error
- func (a *Cache) UpdateType(ctx context.Context, entry *cache.Entry, args []interface{}) (bool, error)
- type Errors
- type FailureHandler
- type IndexSource
- type MultiReader
- type OrderedSource
- type Placeholders
- type Reader
- type RecordMatched
- type SingleSource
- type Source
- func (s *Source) CheckType(ctx context.Context, values []interface{}) (bool, error)
- func (s *Source) Close(ctx context.Context) error
- func (s *Source) ConvertColumns() ([]io.Column, error)
- func (s *Source) Next() bool
- func (s *Source) Rollback(ctx context.Context) error
- func (s *Source) Scanner(ctx context.Context) cache.ScannerFn
- func (s *Source) XTypes() []*xunsafe.Type
- type TimeoutConfig
- type UnorderedSource
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
type FailureHandler ¶ added in v0.2.0
type FailureHandler struct {
// contains filtered or unexported fields
}
func NewFailureHandler ¶ added in v0.2.0
func NewFailureHandler(limit int64, resetAfter *time.Duration) *FailureHandler
func (*FailureHandler) Close ¶ added in v0.2.0
func (f *FailureHandler) Close() error
func (*FailureHandler) HandleFailure ¶ added in v0.2.0
func (f *FailureHandler) HandleFailure()
func (*FailureHandler) HandleSuccess ¶ added in v0.2.0
func (f *FailureHandler) HandleSuccess()
func (*FailureHandler) IsProbing ¶ added in v0.2.0
func (f *FailureHandler) IsProbing() bool
type IndexSource ¶
type IndexSource interface { Close() error Index(value interface{}) *cache.Indexed ColumnIndex() int }
func NewIndexSource ¶
type MultiReader ¶
type MultiReader struct {
// contains filtered or unexported fields
}
func NewMultiReader ¶
func NewMultiReader(matcher *cache.ParmetrizedQuery) *MultiReader
func (*MultiReader) AddReader ¶
func (m *MultiReader) AddReader(reader *Reader)
func (*MultiReader) Close ¶
func (m *MultiReader) Close() error
type OrderedSource ¶
type OrderedSource struct {
// contains filtered or unexported fields
}
func NewOrderedSource ¶
func NewOrderedSource(dest chan *cache.Indexed, index int) *OrderedSource
func (*OrderedSource) Close ¶
func (o *OrderedSource) Close() error
func (*OrderedSource) ColumnIndex ¶
func (o *OrderedSource) ColumnIndex() int
func (*OrderedSource) Index ¶
func (o *OrderedSource) Index(value interface{}) *cache.Indexed
type Placeholders ¶
type Placeholders struct {
// contains filtered or unexported fields
}
func NewPlaceholders ¶
func NewPlaceholders(columnIndex int, fields []*cache.Field) *Placeholders
func (*Placeholders) ColumnValue ¶
func (p *Placeholders) ColumnValue() (interface{}, bool)
func (*Placeholders) CreatePlaceholderAt ¶
func (p *Placeholders) CreatePlaceholderAt(i int)
func (*Placeholders) ScanPlaceholders ¶
func (p *Placeholders) ScanPlaceholders() []interface{}
func (*Placeholders) Values ¶
func (p *Placeholders) Values() []interface{}
type RecordMatched ¶
type RecordMatched struct {
// contains filtered or unexported fields
}
type SingleSource ¶
type SingleSource struct {
// contains filtered or unexported fields
}
func NewSingleSource ¶
func NewSingleSource(dest chan *cache.Indexed) *SingleSource
func (*SingleSource) Close ¶
func (s *SingleSource) Close() error
func (*SingleSource) ColumnIndex ¶
func (s *SingleSource) ColumnIndex() int
func (*SingleSource) Index ¶
func (s *SingleSource) Index(value interface{}) *cache.Indexed
type Source ¶
type Source struct {
// contains filtered or unexported fields
}
type TimeoutConfig ¶
func (*TimeoutConfig) Init ¶ added in v0.2.0
func (t *TimeoutConfig) Init()
type UnorderedSource ¶
type UnorderedSource struct {
// contains filtered or unexported fields
}
func NewUnorderedSource ¶
func NewUnorderedSource(dest chan *cache.Indexed, index int) *UnorderedSource
func (*UnorderedSource) Close ¶
func (u *UnorderedSource) Close() error
func (*UnorderedSource) ColumnIndex ¶
func (u *UnorderedSource) ColumnIndex() int
func (*UnorderedSource) Index ¶
func (u *UnorderedSource) Index(columnValue interface{}) *cache.Indexed
Click to show internal directories.
Click to hide internal directories.