client

package
v0.0.0-...-20c71ce Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Connection

type Connection interface {
	Use(dbName string) (err error)
	Execute(sql string, args ...interface{}) (ret [][]interface{}, err error)
	ExecuteAsync(sql string, args ...interface{}) (Future, error)
	BatchInsert(sql string, argsArray [][]interface{}) (err error)
	BatchInsertAsync(sql string, argsArray [][]interface{}) (Future, error)
	Close()
}

func Connect

func Connect(host string, port int, dbName string) (ret Connection, err error)

type Future

type Future interface {
	Get(timeout ...float64) ([][]interface{}, error) // timeout in seconds
}

type RangeArray

type RangeArray [][2]interface{}

func SplitRange

func SplitRange(start interface{}, end interface{}, numParts int) (parts RangeArray)

Jump to

Keyboard shortcuts

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