Documentation ¶
Index ¶
- Constants
- Variables
- type ID
- type Ident
- type RUID
- func (r RUID) ByteSize() (size int)
- func (r RUID) Bytes() []byte
- func (r *RUID) Deserialize(input *tygo.ProtoBuf) (err error)
- func (r RUID) Ge(o ID) bool
- func (r RUID) Hash() ID
- func (r RUID) Lt(o ID) bool
- func (r RUID) Nonzero() bool
- func (r RUID) Serialize(output *tygo.ProtoBuf)
- func (r RUID) String() string
- type RUIdentity
- type Ring
Constants ¶
View Source
const ( VIRTUAL_NODES = 50 DEFAULT_WEIGHT = 1 )
View Source
const ( TIMESTAMP_MASK = 0x1FFFFFFFFFF TIMESTAMP_BITS = 41 HARDWARE_MASK = 0x7FF HARDWARE_BITS = 11 HARDWARE_OFFSET = TIMESTAMP_BITS SEQUENCE_OFFSET = HARDWARE_BITS + HARDWARE_OFFSET )
View Source
const EncodeRUID = "-ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_"
Variables ¶
View Source
var RUIDEncoding = base64.NewEncoding(EncodeRUID).WithPadding(base64.NoPadding)
Functions ¶
This section is empty.
Types ¶
type ID ¶
type RUIdentity ¶
type RUIdentity int
var RUIdent RUIdentity = 0
func (RUIdentity) Deserialize ¶
func (_ RUIdentity) Deserialize(input *tygo.ProtoBuf) (r ID, err error)
func (RUIdentity) GetIDs ¶
func (_ RUIdentity) GetIDs(bytes []byte) (ids []ID)
func (RUIdentity) New ¶
func (_ RUIdentity) New() ID
func (RUIdentity) Zero ¶
func (_ RUIdentity) Zero() ID
Click to show internal directories.
Click to hide internal directories.