Documentation ¶
Index ¶
- func RandomString(length int) string
- type CleanupFunc
- type KeyLock
- type ReadableError
- type SyncMap
- func (m *SyncMap[K, V]) Delete(key K)
- func (m *SyncMap[K, V]) Load(key K) (value V, ok bool)
- func (m *SyncMap[K, V]) LoadAndDelete(key K) (value V, loaded bool)
- func (m *SyncMap[K, V]) LoadOrStore(key K, value V) (actual V, loaded bool)
- func (m *SyncMap[K, V]) Range(f func(key K, value V) bool)
- func (m *SyncMap[K, V]) Store(key K, value V)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RandomString ¶
Types ¶
type CleanupFunc ¶
type CleanupFunc func() error
type KeyLock ¶
type KeyLock struct {
// contains filtered or unexported fields
}
func NewKeyLock ¶
func NewKeyLock() *KeyLock
type ReadableError ¶
type ReadableError struct {
// contains filtered or unexported fields
}
func NewReadableError ¶
func NewReadableError(err error, message string) *ReadableError
func (*ReadableError) Error ¶
func (e *ReadableError) Error() string
func (*ReadableError) Unwrap ¶
func (e *ReadableError) Unwrap() error
type SyncMap ¶
type SyncMap[K comparable, V any] struct { // contains filtered or unexported fields }
func (*SyncMap[K, V]) LoadAndDelete ¶
func (*SyncMap[K, V]) LoadOrStore ¶
Click to show internal directories.
Click to hide internal directories.