Documentation ¶
Overview ¶
* @Descripttion: * @version: * @Author: lfzxs@qq.com * @Date: 2022-11-28 17:44:53 * @LastEditors: lfzxs@qq.com * @LastEditTime: 2022-11-29 17:23:46
* @Descripttion: 雪花ID * @version: * @Author: lfzxs@qq.com * @Date: 2022-11-29 08:58:29 * @LastEditors: lfzxs@qq.com * @LastEditTime: 2022-11-29 16:30:37
* @Descripttion: UUID * @version: * @Author: lfzxs@qq.com * @Date: 2022-11-29 08:55:02 * @LastEditors: lfzxs@qq.com * @LastEditTime: 2022-11-29 16:45:22
Index ¶
Constants ¶
View Source
const ( // 结点idkey Nodeid_key = "nodeid" // 默认结点ID Default_nodeId = int64(1) )
Variables ¶
This section is empty.
Functions ¶
func GetDefauleNodeId ¶
func WithNodeID ¶
Types ¶
type SnowflakeID ¶
type SnowflakeID struct {
// contains filtered or unexported fields
}
雪花id
func (*SnowflakeID) GetName ¶
func (self *SnowflakeID) GetName() string
func (*SnowflakeID) SnowflakeId ¶
func (self *SnowflakeID) SnowflakeId(pairs ...types.Pair) int64
Click to show internal directories.
Click to hide internal directories.