session

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: 36 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

Overview

Package session handles IMAP commands received from clients within a single IMAP session (one client connection).

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrCreateInbox = errors.New("cannot create INBOX")
	ErrDeleteInbox = errors.New("cannot delete INBOX")
	ErrReadOnly    = errors.New("the mailbox is read-only")

	ErrTLSUnavailable       = errors.New("TLS is unavailable")
	ErrNotAuthenticated     = errors.New("session is not authenticated")
	ErrAlreadyAuthenticated = errors.New("session is already authenticated")

	ErrNotImplemented = errors.New("not implemented")
)
View Source
var ErrFlagRecentIsReserved = errors.New(`system flag \Recent is reserved`)

Functions

This section is empty.

Types

type Session

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

func New

func New(
	conn net.Conn,
	backend *backend.Backend,
	sessionID int,
	version version.Info,
	profiler profiling.CmdProfilerBuilder,
	eventCh chan<- events.Event,
	idleBulkTime time.Duration,
	panicHandler async.PanicHandler,
) *Session

func (*Session) Serve

func (s *Session) Serve(ctx context.Context) error

func (*Session) SetIncomingLogger

func (s *Session) SetIncomingLogger(w io.Writer)

func (*Session) SetOutgoingLogger

func (s *Session) SetOutgoingLogger(w io.Writer)

func (*Session) SetTLSConfig

func (s *Session) SetTLSConfig(cfg *tls.Config)

func (*Session) WriteResponse

func (s *Session) WriteResponse(res string) error

Jump to

Keyboard shortcuts

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