Documentation ¶
Overview ¶
Implements the IMAP UIDPLUS extension, as defined in RFC 4315.
Index ¶
- Constants
- type Client
- func (c *Client) Append(mbox string, flags []string, date time.Time, msg imap.Literal) (validity, uid uint32, err error)
- func (c *Client) Copy(seqset *imap.SeqSet, dest string) (validity uint32, srcUids, dstUids *imap.SeqSet, err error)
- func (c *Client) SupportUidPlus() (bool, error)
- func (c *Client) UidCopy(seqset *imap.SeqSet, dest string) (validity uint32, srcUids, dstUids *imap.SeqSet, err error)
- func (c *Client) UidExpunge(seqSet *imap.SeqSet, ch chan uint32) error
- type ExpungeCommand
- type UidPlusClient
Constants ¶
const ( CodeAppendUid = "APPENDUID" CodeCopyUid = "COPYUID" CodeUidNotSticky = "UIDNOTSTICKY" )
Additional response codes, defined in RFC 4315 section 3.
const Capability = "UIDPLUS"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a UIDPLUS client.
func (*Client) Append ¶
func (c *Client) Append(mbox string, flags []string, date time.Time, msg imap.Literal) (validity, uid uint32, err error)
Append is the same as Client.Append, but can also return the UID of the appended message and the UID validity of the destination mailbox. The server can choose not to return these values, in this case uid and validity will be equal to zero.
func (*Client) Copy ¶
func (c *Client) Copy(seqset *imap.SeqSet, dest string) (validity uint32, srcUids, dstUids *imap.SeqSet, err error)
Copy is the same as Client.Copy, but can also return the source and destination UIDs of the copied messages.
func (*Client) SupportUidPlus ¶
SupportUidPlus checks if the server supports the UIDPLUS extension.
func (*Client) UidCopy ¶
func (c *Client) UidCopy(seqset *imap.SeqSet, dest string) (validity uint32, srcUids, dstUids *imap.SeqSet, err error)
UidCopy is the same as Client.UidCopy, but can also return the source and destination UIDs of the copied messages.
func (*Client) UidExpunge ¶
UidExpunge permanently removes all messages that both have the \Deleted flag set and have a UID that is included in the specified sequence set from the currently selected mailbox.
type ExpungeCommand ¶
type ExpungeCommand struct {
SeqSet *imap.SeqSet
}
An UID EXPUNGE command, as defined in RFC 4315 section 2.1.
func (*ExpungeCommand) Command ¶
func (cmd *ExpungeCommand) Command() *imap.Command
func (*ExpungeCommand) Parse ¶
func (cmd *ExpungeCommand) Parse(fields []interface{}) error
type UidPlusClient ¶
type UidPlusClient = Client
UidPlusClient is an alias used to compose multiple client extensions.