Documentation
¶
Overview ¶
Package pyimaplib is an IMAP4 client with the command, response and error behaviour of CPython imaplib
Index ¶
- type Error
- type IMAP4
- func (m *IMAP4) Login(user, password string) (string, []any, error)
- func (m *IMAP4) Logout() (string, []any, error)
- func (m *IMAP4) Select(mailbox string) (string, []any, error)
- func (m *IMAP4) Shutdown()
- func (m *IMAP4) Starttls(ctx context.Context, tlsConfig *tls.Config) error
- func (m *IMAP4) UID(command string, args ...string) (string, []any, error)
- func (m *IMAP4) Xatom(name string, args ...string) (string, []any, error)
- type Literal
- type OSError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Error ¶
Error is an IMAP4.error, IMAP4.abort or IMAP4.readonly raised by a command, its str the message
func (*Error) IsAbort ¶
Whether the error is an abort, a service failure that needs a fresh connection
func (*Error) PyTypeName ¶
type IMAP4 ¶
type IMAP4 struct {
// Capabilities the server advertised, upper cased
Capabilities []string
// contains filtered or unexported fields
}
One IMAP4 connection with its protocol state and pending responses
func Open ¶
func Open(ctx context.Context, host string, port int, timeout time.Duration, tlsConfig *tls.Config) (*IMAP4, error)
Opens a connection, over implicit TLS when a config is given, reads the greeting and the capabilities
func (*IMAP4) Login ¶
Identifies the client with a plain text password and enters the authenticated state
func (*IMAP4) Select ¶
Selects a mailbox for read and write access, the state falling back to authenticated when the server refuses