dbproxy

package
v0.0.0-...-c0334d6 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RedisConnectLocal

func RedisConnectLocal(conf RedisConfig) bool

RedisConnectLocal TODO.

func RedisConnectRemote

func RedisConnectRemote(conf RedisConfig) bool

RedisConnectRemote TODO.

func RedisMarshal

func RedisMarshal(data interface{}) []byte

RedisMarshal convert interface{} to redis data. (json type.)

func RedisMarshalWithGob

func RedisMarshalWithGob(data interface{}) *bytes.Buffer

RedisMarshalWithGob convert interface{} to redis data.

func RedisUnmarshal

func RedisUnmarshal(data []byte, reply interface{})

RedisUnmarshal convert redis data to interface{}. (json type.)

func RedisUnmarshalWithGob

func RedisUnmarshalWithGob(data []byte, reply interface{})

RedisUnmarshalWithGob convert redis data to interface{}.

func RedisValues

func RedisValues(reply interface{}, err error) ([]interface{}, error)

RedisValues convert interface{} to []interface{}

Types

type MongoDB

type MongoDB struct {
}

MongoDB TODO.

func NewMongoDB

func NewMongoDB() *MongoDB

NewMongoDB TODO.

type Mysql

type Mysql struct {
}

Mysql TODO.

func NewMysql

func NewMysql() *Mysql

NewMysql TODO.

type Redis

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

Redis TODO

var InsRedisLocal *Redis

InsRedisLocal local redis instance.

var InsRedisRemote *Redis

InsRedisRemote remote redis instance.

func (*Redis) ReadCommand

func (owner *Redis) ReadCommand(cmd string, args ...interface{}) (interface{}, error)

ReadCommand TODO

func (*Redis) ReadCommands

func (owner *Redis) ReadCommands(cmd string, args ...interface{}) error

ReadCommands TODO

func (*Redis) ReadCommandsFlush

func (owner *Redis) ReadCommandsFlush() error

ReadCommandsFlush TODO

func (*Redis) ReadCommandsReply

func (owner *Redis) ReadCommandsReply() (interface{}, error)

ReadCommandsReply TODO

func (*Redis) WriteCommand

func (owner *Redis) WriteCommand(cmd string, args ...interface{}) (interface{}, error)

WriteCommand TODO

func (*Redis) WriteCommands

func (owner *Redis) WriteCommands(cmd string, args ...interface{}) error

WriteCommands TODO

func (*Redis) WriteCommandsFlush

func (owner *Redis) WriteCommandsFlush() error

WriteCommandsFlush TODO

func (*Redis) WriteCommandsReply

func (owner *Redis) WriteCommandsReply() (interface{}, error)

WriteCommandsReply TODO

type RedisConfig

type RedisConfig struct {
	Flag     int32
	Type     string
	Host     string
	Port     int32
	Database int32
	Password string
}

RedisConfig TODO

Jump to

Keyboard shortcuts

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