Documentation
¶
Index ¶
- type Conn
- type Option
- func WithAttribute(key string, val string) Option
- func WithCollation(collation *core.Collation) Option
- func WithHost(host string) Option
- func WithInsecureSkipVerify(insecureSkipVerify bool) Option
- func WithLocation(loc *time.Location) Option
- func WithPassword(password string) Option
- func WithPort(port int) Option
- func WithSSLCA(sslCA string) Option
- func WithSSLCert(sslCert string) Option
- func WithSSLKey(sslKey string) Option
- func WithUseSSL(useSSL bool) Option
- func WithUser(user string) Option
- type Rows
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Conn ¶
type Conn interface {
Capabilities() core.CapabilityFlag
AffectedRows() uint64
LastInsertId() uint64
ReadPacket() ([]byte, error)
WritePacket(packet.Packet) error
WriteCommandPacket(packet.Packet) error
Exec(string) (*mysql.Result, error)
Query(string) (Rows, error)
Ping() error
Close() error
}
func CreateConnection ¶
type Option ¶
type Option interface {
// contains filtered or unexported methods
}
func WithAttribute ¶
func WithCollation ¶ added in v1.0.5
func WithInsecureSkipVerify ¶ added in v1.0.5
func WithLocation ¶ added in v1.0.5
func WithPassword ¶
func WithSSLCert ¶ added in v1.0.5
func WithSSLKey ¶ added in v1.0.5
func WithUseSSL ¶ added in v1.0.5
type Rows ¶ added in v1.0.5
type Rows interface {
Columns() []packet.Column
Next() (packet.Row, error)
// HasNextResultSet is called at the end of the current result set and
// reports whether there is another result set after the current one.
HasNextResultSet() bool
// NextResultSet advances the driver to the next result set even
// if there are remaining rows in the current result set.
//
// NextResultSet should return io.EOF when there are no more result sets.
NextResultSet() error
}
Click to show internal directories.
Click to hide internal directories.