response

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: 7 Imported by: 0

Documentation

Overview

Package response implements types used when sending IMAP responses back to clients.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Bad

func Bad(withTag ...string) *bad

func Bye

func Bye() *bye

func Capability

func Capability() *capability

func Continuation

func Continuation() *continuation

func Exists

func Exists() *exists

func Expunge

func Expunge(seq imap.SeqID) *expunge

func Fetch

func Fetch(seq imap.SeqID) *fetch

func Flags

func Flags() *flags

func ID added in v0.8.0

func ID(id imap.IMAPID) *idResponse

func ItemAppendUID

func ItemAppendUID(uidValidity, messageUID imap.UID) *itemAppendUID

func ItemBadCharset added in v0.9.0

func ItemBadCharset() *itemBadCharset

func ItemBody

func ItemBody(structure string) *itemBody

func ItemBodyLiteral

func ItemBodyLiteral(section string, literal []byte) *itemBodyLiteral

func ItemBodyStructure

func ItemBodyStructure(structure string) *itemBodyStructure

func ItemCapability

func ItemCapability(caps ...imap.Capability) *itemCapability

func ItemCopyUID

func ItemCopyUID(uidValidity imap.UID, sourceSet, destSet []imap.UID) *itemCopyUID

func ItemEnvelope

func ItemEnvelope(envelope string) *itemEnvelope

func ItemExpungeIssued

func ItemExpungeIssued() *itemExpungeIssued

func ItemFlags

func ItemFlags(flags imap.FlagSet) *itemFlags

func ItemInternalDate

func ItemInternalDate(date time.Time) *itemInternalDate

func ItemMessages

func ItemMessages(n int) *itemMessages

func ItemPermanentFlags

func ItemPermanentFlags(flags imap.FlagSet) *itemPermanentFlags

func ItemRFC822Header

func ItemRFC822Header(header []byte) *itemRFC822Header

func ItemRFC822Literal

func ItemRFC822Literal(literal []byte) *itemRFC822Literal

func ItemRFC822Size

func ItemRFC822Size(size int) *itemRFC822Size

func ItemRFC822Text

func ItemRFC822Text(text []byte) *itemRFC822Text

func ItemReadOnly

func ItemReadOnly() *itemReadOnly

func ItemReadWrite

func ItemReadWrite() *itemReadWrite

func ItemRecent

func ItemRecent(n int) *itemRecent

func ItemTryCreate

func ItemTryCreate() *itemTryCreate

func ItemUID

func ItemUID(n imap.UID) *itemUID

func ItemUIDNext

func ItemUIDNext(n imap.UID) *itemUIDNext

func ItemUIDValidity

func ItemUIDValidity(n imap.UID) *itemUIDValidity

func ItemUnseen

func ItemUnseen(n uint32) *itemUnseen

func List

func List() *list

func Lsub

func Lsub() *lsub

func No

func No(withTag ...string) *no

func Ok

func Ok(withTag ...string) *ok

func Recent

func Recent() *recent
func Search(seqs ...uint32) *search

func Status

func Status() *status

Types

type Item

type Item interface {
	String() string
}

type Response

type Response interface {
	Send(Session) error
	String() string
}

func FromError

func FromError(err error) (Response, bool)

func Merge added in v0.12.0

func Merge(input []Response) []Response

type Session

type Session interface {
	WriteResponse(string) error
}

Jump to

Keyboard shortcuts

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