tzcache

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2025 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache[K comparable] struct {
	// contains filtered or unexported fields
}

Cache saves and manages the timezone location cache

func NewCache

func NewCache[K comparable]() *Cache[K]

func (*Cache[K]) Add

func (c *Cache[K]) Add(key K, tz string) (*time.Location, bool)

func (*Cache[K]) Get

func (c *Cache[K]) Get(key K) (*time.Location, bool)

func (*Cache[K]) Location

func (c *Cache[K]) Location(tz string) (*time.Location, bool)

Jump to

Keyboard shortcuts

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