utccheck

package
v1.104.0-rc Latest Latest
Warning

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

Go to latest
Published: May 8, 2024 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Conn

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

Conn wraps a driver.Conn with utc checks.

func WrapConn

func WrapConn(conn driver.Conn) *Conn

WrapConn wraps a driver.Conn with utc checks.

func (*Conn) Begin

func (c *Conn) Begin() (driver.Tx, error)

Begin returns a wrapped driver.Tx with utc checks.

func (*Conn) BeginTx

func (c *Conn) BeginTx(ctx context.Context, opts driver.TxOptions) (driver.Tx, error)

BeginTx returns a wrapped driver.Tx with utc checks.

func (*Conn) Close

func (c *Conn) Close() error

Close closes the conn.

func (*Conn) Exec

func (c *Conn) Exec(query string, args []driver.Value) (driver.Result, error)

Exec checks the arguments for non-utc timestamps and returns the result.

func (*Conn) ExecContext

func (c *Conn) ExecContext(ctx context.Context, query string, args []driver.NamedValue) (driver.Result, error)

ExecContext checks the arguments for non-utc timestamps and returns the result.

func (*Conn) Ping

func (c *Conn) Ping(ctx context.Context) error

Ping implements driver.Pinger.

func (*Conn) Prepare

func (c *Conn) Prepare(query string) (driver.Stmt, error)

Prepare returns a wrapped driver.Stmt with utc checks.

func (*Conn) PrepareContext

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

PrepareContext checks the arguments for non-utc timestamps and returns the result.

func (*Conn) Query

func (c *Conn) Query(query string, args []driver.Value) (driver.Rows, error)

Query checks the arguments for non-utc timestamps and returns the result.

func (*Conn) QueryContext

func (c *Conn) QueryContext(ctx context.Context, query string, args []driver.NamedValue) (driver.Rows, error)

QueryContext checks the arguments for non-utc timestamps and returns the result.

func (*Conn) Unwrap

func (c *Conn) Unwrap() driver.Conn

Unwrap returns the underlying driver.Conn.

type Connector

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

Connector wraps a driver.Connector with utc checks.

func WrapConnector

func WrapConnector(connector driver.Connector) *Connector

WrapConnector wraps a driver.Connector with utc checks.

func (*Connector) Connect

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

Connect returns a wrapped driver.Conn with utc checks.

func (*Connector) Driver

func (c *Connector) Driver() driver.Driver

Driver returns a wrapped driver.Driver with utc checks.

func (*Connector) Unwrap

func (c *Connector) Unwrap() driver.Connector

Unwrap returns the underlying driver.Connector.

type Driver

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

Driver wraps a driver.Driver with utc checks.

func WrapDriver

func WrapDriver(driver driver.Driver) *Driver

WrapDriver wraps a driver.Driver with utc checks.

func (*Driver) Open

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

Open returns a wrapped driver.Conn with utc checks.

func (*Driver) Unwrap

func (d *Driver) Unwrap() driver.Driver

Unwrap returns the underlying driver.Driver.

type Stmt

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

Stmt wraps a driver.Stmt with utc checks.

func WrapStmt

func WrapStmt(stmt driver.Stmt) *Stmt

WrapStmt wraps a driver.Stmt with utc checks.

func (*Stmt) Close

func (s *Stmt) Close() error

Close closes the stmt.

func (*Stmt) Exec

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

Exec checks the arguments for non-utc timestamps and returns the result.

func (*Stmt) NumInput

func (s *Stmt) NumInput() int

NumInput returns the number of inputs to the stmt.

func (*Stmt) Query

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

Query checks the arguments for non-utc timestamps and returns the result.

func (*Stmt) Unwrap

func (s *Stmt) Unwrap() driver.Stmt

Unwrap returns the underlying driver.Stmt.

type Tx

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

Tx wraps a driver.Tx with utc checks.

func WrapTx

func WrapTx(tx driver.Tx) *Tx

WrapTx wraps a driver.Tx with utc checks.

func (*Tx) Commit

func (t *Tx) Commit() error

Commit commits the tx.

func (*Tx) Rollback

func (t *Tx) Rollback() error

Rollback rolls the tx back.

func (*Tx) Unwrap

func (t *Tx) Unwrap() driver.Tx

Unwrap returns the underlying driver.Tx.

Jump to

Keyboard shortcuts

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