model

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BitSize = 256
)

Variables

This section is empty.

Functions

func NewHashIDUint64

func NewHashIDUint64(key string) uint64

Types

type HashID

type HashID []byte

func BytesToHashID

func BytesToHashID(b []byte) HashID

func NewHashID

func NewHashID(key string) HashID

func (HashID) Add

func (h HashID) Add(offset int64) HashID

func (HashID) Between

func (h HashID) Between(from HashID, to HashID) bool

func (HashID) Equals

func (h HashID) Equals(other HashID) bool

func (HashID) GreaterThan

func (h HashID) GreaterThan(other HashID) bool

func (HashID) GreaterThanEqual

func (h HashID) GreaterThanEqual(other HashID) bool

func (HashID) LessThan

func (h HashID) LessThan(other HashID) bool

func (HashID) LessThanEqual

func (h HashID) LessThanEqual(other HashID) bool

type NodeRef

type NodeRef struct {
	ID   HashID
	Host string
}

func NewNodeRef

func NewNodeRef(host string) *NodeRef

Jump to

Keyboard shortcuts

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