counter

package
v0.14.2 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FilterSkillName = config.TypeName(reflect.TypeOf((*IClient)(nil)).Elem())
)

Functions

func GetRemainCount

func GetRemainCount(client IClient, key string, count int64, variables eosc.Untyped[string, string]) (int64, error)

Types

type IClient

type IClient interface {
	Get(variables eosc.Untyped[string, string]) (int64, error)
}

type ICounter

type ICounter interface {
	// Lock 锁定次数
	Lock(count int64) error
	// Complete 完成扣次操作
	Complete(count int64) error
	// RollBack 回滚
	RollBack(count int64) error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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