map_counter

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: May 23, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Map

type Map interface {
	// Finds the exisiting contract counter or initialises a new one,
	// and always retuns a new child counter
	GetOrInit(key string) (value *synccounters.ConnCounter)
	// Iterate over the entire itemlist
	// f should return false to abort iteration
	// Range(f) returns if iteration was completed
	Range(f func(key string, value *synccounters.ContractCounter) bool) bool
	// Reset values to 0
	// Returns a map[string]uint64 with the previous values, and a completion flag
	Reset() (map[string]uint64, bool)
}

func NewList

func NewList() Map

type Tuple

type Tuple struct {
	Key string
	Val *synccounters.ContractCounter
}

Jump to

Keyboard shortcuts

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