package
1.0.0-rc.3
Repository: https://github.com/iotaledger/hive.go.git
Documentation: pkg.go.dev

# Functions

New returns a ThresholdMap that operates in the given Mode and that can also receive an optional comparator function to support custom key types.
NewIterator is the constructor of the Iterator that takes the starting Element as its parameter.

# Constants

InitialState is the state of the Iterator before the first Element has been retrieved.
IterationStartedState is the state of the Iterator after the first Element has been retrieved and before we have reached either the first or the last Element.
LeftEndReachedState is the state of the Iterator after we have reached the smallest Element.
LowerThresholdMode interprets the keys of the ThresholdMap as lower thresholds which means that querying the map will return the value of the largest node whose key is <= than the queried value.
RightEndReachedState is the state of the Iterator after we have reached the largest Element.
UpperThresholdMode interprets the keys of the ThresholdMap as upper thresholds which means that querying the map will return the value of the smallest node whose key is >= than the queried value.

# Structs

Element is a wrapper for the Node used in the underlying red-black RedBlackTree.
Iterator is an object that allows to iterate over the ThresholdMap by providing methods to walk through the map in a deterministic order.
ThresholdMap is a data structure that allows to map keys bigger or lower than a certain threshold to a given value.

# Type aliases

IteratorState represents the state of the Iterator that is used to track where in the set of contained Elements the pointer is currently located.
Mode encodes different modes of function for the ThresholdMap that specifies if the defines keys act as upper or lower thresholds.