• Skip to content
  • Skip to link menu
KDE 4.6 API Reference
  • KDE API Reference
  • KDE-PIM Libraries
  • KDE Home
  • Contact Us
 

KIMAP Library

  • KIMAP
  • CopyJob
Public Member Functions | Protected Member Functions
KIMAP::CopyJob Class Reference

Copies one or more messages to another mailbox. More...

#include <copyjob.h>

Inherits KIMAP::Job.

List of all members.

Public Member Functions

 CopyJob (Session *session)
bool isUidBased () const
QString mailBox () const
ImapSet resultingUids () const
ImapSet sequenceSet () const
void setMailBox (const QString &mailBox)
void setSequenceSet (const ImapSet &set)
void setUidBased (bool uidBased)

Protected Member Functions

virtual void doStart ()
virtual void handleResponse (const Message &response)

Detailed Description

Copies one or more messages to another mailbox.

This job can only be run when the session is in the selected state.

If the server supports ACLs, the user will need the Acl::Insert right on the target mailbox. In order to preserve message flags, the user may also need some combination of Acl::DeleteMessage, Acl::KeepSeen and Acl::Write on the target mailbox.

Definition at line 46 of file copyjob.h.


Member Function Documentation

bool CopyJob::isUidBased ( ) const

How to interpret the sequence set.

Returns:
if true the result of sequenceSet() should be interpreted as UIDs, if false it should be interpreted as sequence numbers

Definition at line 91 of file copyjob.cpp.

QString CopyJob::mailBox ( ) const

The destination mailbox.

Definition at line 66 of file copyjob.cpp.

ImapSet CopyJob::resultingUids ( ) const

The UIDs of the new copies of the messages.

This will be an empty set if no messages have been copied yet or if the server does not support the UIDPLUS extension.

Definition at line 97 of file copyjob.cpp.

ImapSet CopyJob::sequenceSet ( ) const

The messages that will be copied.

isUidBased() can be used to check whether the ImapSet contains sequence numbers or UIDs.

Returns:
the sequence numbers or UIDs of the messages to be copied

Definition at line 78 of file copyjob.cpp.

void CopyJob::setMailBox ( const QString &  mailBox)

Sets the destination mailbox.

If the mailbox does not exist, the server should not create it automatically and the job should fail. Note, however, that a conforming server may create the mailbox automatically.

Parameters:
mailBoxthe (unquoted) name of the mailbox where the messages should be copied to

Definition at line 60 of file copyjob.cpp.

void CopyJob::setSequenceSet ( const ImapSet &  set)

Sets the messages to be copied.

If sequence numbers are given, isUidBased() should be false. If UIDs are given, isUidBased() should be true.

RFC 3501 is unclear as to what should happen if invalid sequence numbers are passed. If non-existent UIDs are passed, they will be ignored.

Parameters:
setthe sequence numbers or UIDs of the messages to be copied

Definition at line 72 of file copyjob.cpp.

void CopyJob::setUidBased ( bool  uidBased)

Set how the sequence set should be interpreted.

Parameters:
uidBasedif true the argument to setSequenceSet will be interpreted as UIDs, if false it will be interpreted as sequence numbers

Definition at line 85 of file copyjob.cpp.


The documentation for this class was generated from the following files:
  • copyjob.h
  • copyjob.cpp

KIMAP Library

Skip menu "KIMAP Library"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

KDE-PIM Libraries

Skip menu "KDE-PIM Libraries"
  • akonadi
  •   contact
  •   kmime
  • kabc
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  •   richtextbuilders
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Generated for KDE-PIM Libraries by doxygen 1.7.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal