model

package
v0.0.0-...-83adff0 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2020 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	EmptyAchieve         = AchieveFlag(0)
	FollowerAchieve1k    = AchieveFlag(1 << 0)
	FollowerAchieve5k    = AchieveFlag(1 << 1)
	FollowerAchieve10k   = AchieveFlag(1 << 2)
	FollowerAchieve100k  = AchieveFlag(1 << 3)
	FollowerAchieve1000k = AchieveFlag(1 << 12)
)

const

Functions

This section is empty.

Types

type AchieveFlag

type AchieveFlag uint64

AchieveFlag is

func AchieveFromFollower

func AchieveFromFollower(count int64) AchieveFlag

AchieveFromFollower is

func AllAchieveFromFollower

func AllAchieveFromFollower(count int64) []AchieveFlag

AllAchieveFromFollower is

type Message

type Message struct {
	Action string          `json:"action"`
	Table  string          `json:"table"`
	New    json.RawMessage `json:"new"`
	Old    json.RawMessage `json:"old"`
}

Message define binlog databus message.

type Relation

type Relation struct {
	Mid       int64  `json:"mid,omitempty"`
	Fid       int64  `json:"fid,omitempty"`
	Attribute uint32 `json:"attribute"`
	Status    int    `json:"status"`
	MTime     string `json:"mtime"`
	CTime     string `json:"ctime"`
}

Relation user_relation_fid_0~user_relation_fid_49,user_relation_mid_0~user_relation_mid_49

func (*Relation) Attr

func (r *Relation) Attr() uint32

Attr is.

func (*Relation) IsRecent

func (r *Relation) IsRecent(at time.Time, trange time.Duration) bool

IsRecent is.

func (*Relation) LastChangeAt

func (r *Relation) LastChangeAt() (at time.Time, err error)

LastChangeAt is.

type Stat

type Stat struct {
	Mid       int64 `json:"mid,omitempty"`
	Following int64 `json:"following"`
	Whisper   int64 `json:"whisper"`
	Black     int64 `json:"black"`
	Follower  int64 `json:"follower"`
}

Stat user_relation_stat

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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