Documentation ¶
Overview ¶
Package uidplus DOES NOT implement full RFC4315!
Excluded parts are:
- Response `UIDNOTSTICKY`: All mailboxes of Bridge support stable UIDVALIDITY so it would never return this response
Otherwise the standard RFC4315 is followed.
Index ¶
Constants ¶
const Capability = "UIDPLUS"
Capability extension identifier.
Variables ¶
This section is empty.
Functions ¶
func AppendResponse ¶
func AppendResponse(uidValidity uint32, targetSeq *OrderedSeq) error
AppendResponse prepares OK response with extended UID information about appended message.
func CopyResponse ¶
func CopyResponse(uidValidity uint32, sourceSeq, targetSeq *OrderedSeq) error
CopyResponse prepares OK response with extended UID information about copied message.
Types ¶
type OrderedSeq ¶
type OrderedSeq []uint32
OrderedSeq to remember Seq in order they are added. We didn't find any restriction in RFC that server must respond with ranges so we decided to always do explicit list. This makes sure that no dynamic ranges or out of the bound ranges are possible.
NOTE: potential issue with response length
- the user selects large number of messages to be copied and the response line will be long,
- list of UIDs which high values
which can create long response line. We didn't find a maximum length of one IMAP response line or maximum length of IMAP "response code" with parameters.
func (*OrderedSeq) Add ¶
func (os *OrderedSeq) Add(num uint32)
Add number to sequence. Zero is not acceptable UID and it won't be added to list.
func (*OrderedSeq) String ¶
func (os *OrderedSeq) String() string
type UIDExpunge ¶
type UIDExpunge struct {
SeqSet *imap.SeqSet
}
func (*UIDExpunge) Parse ¶
func (e *UIDExpunge) Parse(fields []interface{}) error