cache

package
v0.0.0-...-2f442fc Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ClearBalance

func ClearBalance(pkHash []byte) error

func ClearHasPic

func ClearHasPic(pkHash []byte) error

func ClearReputation

func ClearReputation(selfPkHash []byte, pkHash []byte) error

func DeleteItem

func DeleteItem(name string) error

func GetAndSetUnreadNotificationCount

func GetAndSetUnreadNotificationCount(userId uint) (uint, error)

func GetBalance

func GetBalance(pkHash []byte) (int64, error)

func GetItem

func GetItem(name string, value interface{}) error

func GetLastTopicList

func GetLastTopicList(cookieId string) (string, error)

func GetUnreadNotificationCount

func GetUnreadNotificationCount(userId uint) (uint, error)

func GetUserAddress

func GetUserAddress(userId uint) (wallet.Address, error)

func GetUserPkHash

func GetUserPkHash(userId uint) ([]byte, error)

func GetUserSettings

func GetUserSettings(userId uint) (*db.UserSettings, error)

func IsMissError

func IsMissError(err error) bool

func SetBalance

func SetBalance(pkHash []byte, balance int64) error

func SetItem

func SetItem(name string, value interface{}) error

func SetItemWithExpiration

func SetItemWithExpiration(name string, value interface{}, expireSeconds int32) error

func SetLastTopicList

func SetLastTopicList(cookieId string, topicList string) error

func SetProfilePic

func SetProfilePic(pkHash []byte, profilePic ProfilePic) error

func SetReputation

func SetReputation(selfPkHash []byte, pkHash []byte, reputation *Reputation) error

func SetUnreadNotificationCount

func SetUnreadNotificationCount(userId uint, count uint) error

func SetUserSettings

func SetUserSettings(settings *db.UserSettings) error

Types

type ProfilePic

type ProfilePic struct {
	Has       bool
	Id        uint
	Extension string
}

func GetProfilePic

func GetProfilePic(pkHash []byte) (ProfilePic, error)

type Reputation

type Reputation struct {
	TrustedFollowers int
	TotalFollowing   int
	DirectFollow     bool
}

func GetReputation

func GetReputation(selfPkHash []byte, pkHash []byte) (*Reputation, error)

type UnreadNotifications

type UnreadNotifications struct {
	Count uint
}

type UserAddress

type UserAddress struct {
	PkHash []byte
}

Jump to

Keyboard shortcuts

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