selector

package
v0.0.0-...-570c91f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 19, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const OptionUseZeroLenSliceOnNull = iota

Variables

This section is empty.

Functions

This section is empty.

Types

type Option

type Option int

type Options

type Options []Option

func (Options) Contains

func (o Options) Contains(option Option) bool

type S

type S[T any] struct {
	DB *bun.DB
}

func New

func New[T any](db *bun.DB) S[T]

func (S[T]) SelectMany

func (r S[T]) SelectMany(ctx context.Context, fn func(q *bun.SelectQuery) *bun.SelectQuery, options ...Option) ([]*T, error)

func (S[T]) SelectOne

func (r S[T]) SelectOne(ctx context.Context, fn func(q *bun.SelectQuery) *bun.SelectQuery) (*T, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL