utils

package
v0.17.0 Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2023 License: MIT Imports: 5 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrCause added in v0.16.0

func ErrCause(err error) error

ErrCause returns the cause of the error, the inner-most error in the wrapped chain.

func NewRandomMailboxID added in v0.13.0

func NewRandomMailboxID() string

NewRandomMailboxID return a new random mailbox ID. For debugging purposes, the ID starts with the 'lbl-' prefix.

func NewRandomMessageID

func NewRandomMessageID() string

NewRandomMessageID return a new random message ID. For debugging purposes, the ID starts with the 'message-' prefix.

func NewRandomUserID

func NewRandomUserID() string

NewRandomUserID return a new random user ID. For debugging purposes, the ID starts with the 'user-' prefix.

Types

type MessageHashesMap added in v0.17.0

type MessageHashesMap struct {
	// contains filtered or unexported fields
}

MessageHashesMap tracks the hashes for a literal and it's associated internal IMAP ID.

func NewMessageHashesMap added in v0.17.0

func NewMessageHashesMap() *MessageHashesMap

func (*MessageHashesMap) Erase added in v0.17.0

func (m *MessageHashesMap) Erase(ids ...imap.InternalMessageID)

Erase removes the info associated with a given id.

func (*MessageHashesMap) Insert added in v0.17.0

func (m *MessageHashesMap) Insert(id imap.InternalMessageID, literal []byte) (bool, error)

Insert inserts the hash of the current message literal into the map and return true if an existing value was already present.

Jump to

Keyboard shortcuts

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