Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MapEntry ¶
type MapEntry[T1 comparable, T2 any] struct { Key T1 Value T2 }
type SyncMap ¶
type SyncMap[T1 comparable, T2 any] struct { // contains filtered or unexported fields }
SyncMap classic synchronized map through RWMutex implementation
func NewSyncMap ¶
func NewSyncMap[T1 comparable, T2 any]() SyncMap[T1, T2]
func (*SyncMap[T1, T2]) Clear ¶
func (sm *SyncMap[T1, T2]) Clear()
Clear clears all entries by recreating internal map
func (*SyncMap[T1, T2]) Delete ¶
func (sm *SyncMap[T1, T2]) Delete(key T1)
Delete key from map with write locking
type TList ¶
type TList[T any] struct { // contains filtered or unexported fields }
TList Struct is to keep buffer with required time interval of incoming data in memory May be used to keep data for calculating moving average
func (*TList[T]) Append ¶
Append data to the end of list and remove first elements out of data Returns true if at least one element was removed
func (*TList[T]) RemoveFirst ¶
RemoveFirst removes first element from TList
Click to show internal directories.
Click to hide internal directories.