dao

package
v0.0.0-...-4cc9216 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Live

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

func NewLive

func NewLive(db *gorm.DB) *Live

func (*Live) AddLiveRoom

func (l *Live) AddLiveRoom(room *base.Room) (int64, error)

func (*Live) GetLiveRoomByID

func (l *Live) GetLiveRoomByID(id int64) (*base.Room, error)

func (*Live) GetOnlineLiveRooms

func (l *Live) GetOnlineLiveRooms() ([]int64, error)

func (*Live) TagStopLiveRoom

func (l *Live) TagStopLiveRoom(id int64) error

type LiveRedis

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

func NewLiveRedis

func NewLiveRedis(rd *redis.Client) *LiveRedis

func (*LiveRedis) AddLiveRoomCache

func (l *LiveRedis) AddLiveRoomCache(ctx context.Context, room *base.Room) error

func (*LiveRedis) DeleteLiveRoomCache

func (l *LiveRedis) DeleteLiveRoomCache(ctx context.Context, id int64) error

func (*LiveRedis) GetLiveRoomCache

func (l *LiveRedis) GetLiveRoomCache(ctx context.Context, id int64) (*base.Room, error)

func (*LiveRedis) GetLiveRoomIsLiveCache

func (l *LiveRedis) GetLiveRoomIsLiveCache(ctx context.Context, id int64) (bool, error)

func (*LiveRedis) GetLiveRoomOwnerCache

func (l *LiveRedis) GetLiveRoomOwnerCache(ctx context.Context, id int64) (int64, error)

func (*LiveRedis) StopLive

func (l *LiveRedis) StopLive(ctx context.Context, id int64) error

Jump to

Keyboard shortcuts

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