utils

package
v1.7.1 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetHeaderFromHeaders

func GetHeaderFromHeaders(headers []types.Header, key string) types.Header

func MapConfigMapToOptions

func MapConfigMapToOptions(config *kafka.ConfigMap) []types.Option

Types

type TypedSyncMap

type TypedSyncMap[K comparable, V any] struct {
	// contains filtered or unexported fields
}

TypedSyncMap es un wrapper genérico sobre sync.Map para tipado fuerte y autocompletado

func NewTypedSyncMap

func NewTypedSyncMap[K comparable, V any]() *TypedSyncMap[K, V]

func (*TypedSyncMap[K, V]) Delete

func (t *TypedSyncMap[K, V]) Delete(key K)

func (*TypedSyncMap[K, V]) Load

func (t *TypedSyncMap[K, V]) Load(key K) (V, bool)

func (*TypedSyncMap[K, V]) LoadOrStore

func (t *TypedSyncMap[K, V]) LoadOrStore(key K, value V) (actual V, loaded bool)

func (*TypedSyncMap[K, V]) Range

func (t *TypedSyncMap[K, V]) Range(f func(key K, value V) bool)

func (*TypedSyncMap[K, V]) Store

func (t *TypedSyncMap[K, V]) Store(key K, value V)

Jump to

Keyboard shortcuts

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