dao

package
v0.0.0-...-c242be3 Latest Latest
Warning

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

Go to latest
Published: Jun 13, 2017 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dao

type Dao struct {
	Redis *Redis
	HBase *HBase
	Mysql *Mysql
}

func NewDao

func NewDao() (dao *Dao)

type HBase

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

func NewHBase

func NewHBase() *HBase

func (*HBase) GetMsgs

func (h *HBase) GetMsgs(ctx context.Context, rowKey string) (res *hrpc.Result, err error)

type Mysql

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

func NewMysql

func NewMysql() (mysql *Mysql)

func (*Mysql) GetUserMsgID

func (mysql *Mysql) GetUserMsgID(c context.Context, uid int64) (userMsgID *model.UserMsgID, err error)

func (*Mysql) UpdateUserMsgID

func (mysql *Mysql) UpdateUserMsgID(c context.Context, uid, currentMsgID int64) (rows int64, err error)

type Redis

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

func NewRedis

func NewRedis() (redis *Redis)

func (*Redis) ExceptionMsg

func (r *Redis) ExceptionMsg(ctx context.Context, msgID string) (res string, err error)

func (*Redis) SetExceptionMsg

func (r *Redis) SetExceptionMsg(ctx context.Context, msgID string, data string) (err error)

func (*Redis) SetNormalMsg

func (r *Redis) SetNormalMsg(ctx context.Context, msgID string, data string) (err error)

Jump to

Keyboard shortcuts

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