Documentation ¶
Index ¶
- func NewFileInfo(name string, size int64, mode fs.FileMode, modTime time.Time, isDir bool) fs.FileInfo
- func RandomString(lenNum int) string
- type ExpireCache
- type LinkList
- func (l *LinkList[T]) Add(v T, num int)
- func (l *LinkList[T]) Dequeue()
- func (l *LinkList[T]) Enqueue(v T)
- func (l *LinkList[T]) Get(index int) T
- func (l *LinkList[T]) GetAll() []T
- func (l *LinkList[T]) Pop()
- func (l *LinkList[T]) Push(v T)
- func (l *LinkList[T]) Remove(index int)
- func (l *LinkList[T]) Size() int
- func (l *LinkList[T]) Walk(fn func(v T) bool)
- type Map
- type RingBuffer
- type Values
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFileInfo ¶
func RandomString ¶
Types ¶
type ExpireCache ¶
type ExpireCache struct { Timeout int64 // contains filtered or unexported fields }
func (*ExpireCache) Delete ¶
func (c *ExpireCache) Delete(key string)
func (*ExpireCache) Load ¶
func (c *ExpireCache) Load(key string) (interface{}, bool)
func (*ExpireCache) Store ¶
func (c *ExpireCache) Store(key string, value interface{})
type RingBuffer ¶
func NewRingBuffer ¶
func NewRingBuffer[T any](size int) *RingBuffer[T]
func (*RingBuffer[T]) Latest ¶
func (r *RingBuffer[T]) Latest() T
func (*RingBuffer[T]) Oldest ¶
func (r *RingBuffer[T]) Oldest() T
func (*RingBuffer[T]) Overwrite ¶
func (r *RingBuffer[T]) Overwrite(v T)
func (*RingBuffer[T]) Read ¶
func (r *RingBuffer[T]) Read() T
func (*RingBuffer[T]) Write ¶
func (r *RingBuffer[T]) Write(value T)
Click to show internal directories.
Click to hide internal directories.