app

package
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2023 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Connect

type Connect struct {
	// contains filtered or unexported fields
}

func NewConnect

func NewConnect(ctx context.Context, dsn client.DataSourceName) (c Connect, err error)

func (Connect) Begin

func (c Connect) Begin() (tx driver.Tx, err error)

func (Connect) BeginTx

func (c Connect) BeginTx(ctx context.Context, _ driver.TxOptions) (tx driver.Tx, err error)

func (Connect) CheckNamedValue

func (c Connect) CheckNamedValue(nv *driver.NamedValue) error

func (Connect) Close

func (c Connect) Close() error

func (Connect) ExecContext

func (c Connect) ExecContext(ctx context.Context, query string, args []driver.NamedValue) (res driver.Result, err error)

func (Connect) IsValid

func (c Connect) IsValid() bool

func (Connect) Prepare

func (c Connect) Prepare(query string) (stmt driver.Stmt, err error)

func (Connect) PrepareContext

func (c Connect) PrepareContext(ctx context.Context, query string) (driver.Stmt, error)

func (Connect) QueryContext

func (c Connect) QueryContext(ctx context.Context, query string, args []driver.NamedValue) (rows driver.Rows, err error)

func (Connect) ResetSession

func (c Connect) ResetSession(_ context.Context) (err error)

type Connector

type Connector struct {
	// contains filtered or unexported fields
}

func (Connector) Connect

func (c Connector) Connect(ctx context.Context) (conn driver.Conn, err error)

func (Connector) Driver

func (c Connector) Driver() driver.Driver

type Driver

type Driver struct {
}

func (Driver) Open

func (d Driver) Open(name string) (c driver.Conn, err error)

func (Driver) OpenConnector

func (d Driver) OpenConnector(name string) (driver.Connector, error)

type Result

type Result struct {
	client.BindExecResponse
}

func (Result) LastInsertId

func (r Result) LastInsertId() (int64, error)

func (Result) RowsAffected

func (r Result) RowsAffected() (int64, error)

type Rows

type Rows struct {
	// contains filtered or unexported fields
}

func (*Rows) Close

func (r *Rows) Close() error

func (*Rows) ColumnTypeDatabaseTypeName

func (r *Rows) ColumnTypeDatabaseTypeName(index int) string

func (*Rows) ColumnTypeLength

func (r *Rows) ColumnTypeLength(index int) (length int64, ok bool)

func (*Rows) ColumnTypeNullable

func (r *Rows) ColumnTypeNullable(_ int) (nullable, ok bool)

func (*Rows) ColumnTypePrecisionScale

func (r *Rows) ColumnTypePrecisionScale(_ int) (precision, scale int64, ok bool)

func (*Rows) ColumnTypeScanType

func (r *Rows) ColumnTypeScanType(index int) reflect.Type

func (*Rows) Columns

func (r *Rows) Columns() (cols []string)

func (*Rows) HasNextResultSet

func (r *Rows) HasNextResultSet() bool

func (*Rows) Next

func (r *Rows) Next(dest []driver.Value) error

func (*Rows) NextResultSet

func (r *Rows) NextResultSet() error

type Statement

type Statement struct {
	Id       string
	SQL      string
	Response client.ParseResponse
	// contains filtered or unexported fields
}

func (Statement) Close

func (s Statement) Close() error

func (Statement) Exec

func (s Statement) Exec(args []driver.Value) (driver.Result, error)

func (Statement) ExecContext

func (s Statement) ExecContext(ctx context.Context, args []driver.NamedValue) (driver.Result, error)

func (Statement) NumInput

func (s Statement) NumInput() int

func (Statement) Query

func (s Statement) Query(args []driver.Value) (driver.Rows, error)

func (Statement) QueryContext

func (s Statement) QueryContext(ctx context.Context, args []driver.NamedValue) (driver.Rows, error)

type Tx

type Tx struct {
	// contains filtered or unexported fields
}

func (Tx) Commit

func (t Tx) Commit() (err error)

func (Tx) Rollback

func (t Tx) Rollback() (err error)

Jump to

Keyboard shortcuts

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