kmfolder.cpp
83 TQString msg = i18n("<qt>Error while creating file <b>%1</b>:<br>%2</qt>").arg(aFolderName).arg(strerror(rc));
170 mExpireAction = config->readEntry("ExpireAction", "Delete") == "Move" ? ExpireMove : ExpireDelete;
218 if ( mIdentity != 0 && ( !mStorage || !mStorage->account() || mIdentity != mStorage->account()->identityId() ) )
907 message = i18n( "Folder names cannot contain the / (slash) character; please choose another folder name." );
913 message = i18n( "Folder names cannot start with a . (dot) character; please choose another folder name." );
virtual void correctUnreadMsgsCount()
A cludge to help make sure the count of unread messges is kept in sync.
Definition: folderstorage.cpp:957
virtual void msgStatusChanged(const KMMsgStatus oldStatus, const KMMsgStatus newStatus, int idx)
Called by KMMsgBase::setStatus when status of a message has changed required to keep the number unrea...
Definition: folderstorage.cpp:864
void statusMsg(const TQString &)
Emmited to display a message somewhere in a status line.
int canAccess()
Check folder for permissions Returns zero if readable and writable.
Definition: kmfolder.cpp:484
virtual KMFolderType folderType() const
Returns the type of this folder.
Definition: folderstorage.h:96
void folderSizeChanged(KMFolder *)
Emitted when the folder's size changes.
void msgRemoved(KMFolder *, TQ_UINT32 sernum)
Emitted before a message is removed from the folder.
virtual TQString fileName() const
Returns the filename of the folder (reimplemented in KMFolderImap)
Definition: folderstorage.cpp:143
void remove()
Removes the folder physically from disk and empties the contents of the folder in memory.
Definition: kmfolder.cpp:515
FolderJob * createJob(KMMessage *msg, FolderJob::JobType jt=FolderJob::tGetMessage, KMFolder *folder=0, TQString partSpecifier=TQString(), const AttachmentStrategy *as=0) const
These methods create respective FolderJob (You should derive FolderJob for each derived KMFolder).
Definition: kmfolder.cpp:346
virtual int find(const KMMsgBase *msg) const =0
Returns the index of the given message or -1 if not found.
TQString fileName() const
Returns the filename of the folder (reimplemented in KMFolderImap)
Definition: kmfolder.cpp:238
const KMMsgBase * getMsgBase(int idx) const
Provides access to the basic message fields that are also stored in the index.
Definition: kmfolder.cpp:360
virtual int updateIndex()=0
Incrementally update the index if possible else call writeIndex.
void viewConfigChanged()
Emitted when the variables for the config of the view have changed.
int find(const KMMsgBase *msg) const
Returns the index of the given message or -1 if not found.
Definition: kmfolder.cpp:435
void cleared()
Emitted when the contents of a folder have been cleared (new search in a search folder,...
bool noContent() const
Returns, if the folder can't contain mails, but only subfolder.
Definition: kmfolder.cpp:301
int countUnreadRecursive()
Number of new or unread messages in this folder and all folders contained by this folder.
Definition: kmfolder.cpp:455
void emitMsgAddedSignals(int idx)
Called by derived classes implementation of addMsg.
Definition: kmfolder.cpp:405
int updateIndex()
Incrementally update the index if possible else call writeIndex.
Definition: kmfolder.cpp:856
KMail list that manages the contents of one directory that may contain folders and/or other directori...
Definition: kmfolderdir.h:15
void msgHeaderChanged(KMFolder *, int)
Emitted when a field of the header of a specific message changed.
void quiet(bool beQuiet)
If set to quiet the folder will not emit msgAdded(idx) signal.
Definition: kmfolder.cpp:556
virtual void setNoChildren(bool aNoChildren)
Specify, that the folder can't have children.
Definition: folderstorage.cpp:1108
virtual int count(bool cache=false) const
Number of messages in this folder.
Definition: folderstorage.cpp:820
void setReadExpireUnits(ExpireUnits units)
Set units to use for expiry of read messages.
Definition: kmfolder.cpp:756
int addMsg(KMMessage *msg, int *index_return=0)
Add the given message to the folder.
Definition: kmfolder.cpp:390
bool isValidName(const TQString &folderName, TQString &message)
Returns true if the name is valid for a child of this folder.
Definition: kmfolder.cpp:899
virtual int writeIndex(bool createEmptyIndex=false)=0
Write index to index-file.
virtual void reallyAddCopyOfMsg(KMMessage *aMsg)
Add a copy of the message to the folder after it has been retrieved from an IMAP server.
Definition: folderstorage.cpp:344
KMFolderDir * createChildFolder()
Create a child folder directory and associates it with this folder.
Definition: kmfolder.cpp:264
virtual const KMMsgBase * getMsgBase(int idx) const =0
Provides access to the basic message fields that are also stored in the index.
virtual void ignoreJobsForMessage(KMMessage *)
Removes and deletes all jobs associated with the particular message.
Definition: folderstorage.cpp:1064
virtual TQString label() const
Returns the label of the folder for visualization.
Definition: kmfolder.cpp:581
void ignoreJobsForMessage(KMMessage *)
Removes and deletes all jobs associated with the particular message.
Definition: kmfolder.cpp:341
void setUnreadExpireUnits(ExpireUnits units)
Set units to use for expiry of unread messages.
Definition: kmfolder.cpp:741
virtual void reallyAddMsg(KMMessage *aMsg)
Add the message to the folder after it has been retrieved from an IMAP server.
Definition: folderstorage.cpp:323
void reallyAddCopyOfMsg(KMMessage *aMsg)
Add a copy of the message to the folder after it has been retrieved from an IMAP server.
Definition: kmfolder.cpp:866
ExpireUnits getReadExpireUnits() const
Units getReadExpireAge() is returned in.
Definition: kmfolder.h:467
void shortcutChanged(KMFolder *)
Emitted when the shortcut associated with this folder changes.
TQString whoField() const
Get / set the name of the field that is used for the Sender/Receiver column in the headers (From/To)
Definition: kmfolder.h:396
Class is used for all Mailing List handling inside KMail.
Definition: mailinglist-magic.h:23
virtual void quiet(bool beQuiet)
If set to quiet the folder will not emit msgAdded(idx) signal.
Definition: folderstorage.cpp:205
void writeConfig(TDEConfig *config) const
This is used by the storage to save the folder specific configuration.
Definition: kmfolder.cpp:200
void setNoChildren(bool aNoChildren)
Specify, that the folder can't have children.
Definition: kmfolder.cpp:316
int rename(const TQString &newName, KMFolderDir *aParent=0)
Physically rename the folder.
Definition: kmfolder.cpp:531
KMFolderDir * child() const
Returns the folder directory associated with this node or 0 if no such directory exists.
Definition: kmfolder.h:157
void msgStatusChanged(const KMMsgStatus oldStatus, const KMMsgStatus newStatus, int idx)
Called by KMMsgBase::setStatus when status of a message has changed required to keep the number unrea...
Definition: kmfolder.cpp:473
void msgChanged(KMFolder *, TQ_UINT32 sernum, int delta)
Emitted, when the status of a message is changed.
void setMailingListEnabled(bool enabled)
Returns true if this folder is associated with a mailing-list.
Definition: kmfolder.cpp:620
virtual int addMsg(KMMessage *msg, int *index_return=0)=0
Add the given message to the folder.
void changed()
Emitted when the status, name, or associated accounts of this folder changed.
void setAutoExpire(bool enabled)
Set whether this folder automatically expires messages.
Definition: kmfolder.cpp:725
void correctUnreadMsgsCount()
A cludge to help make sure the count of unread messges is kept in sync.
Definition: kmfolder.cpp:700
void reallyAddMsg(KMMessage *aMsg)
Add the message to the folder after it has been retrieved from an IMAP server.
Definition: kmfolder.cpp:861
KMMsgInfo * unGetMsg(int idx)
Replace KMMessage with KMMsgInfo and delete KMMessage
Definition: kmfolder.cpp:326
virtual KMFolder * trashFolder() const
If this folder has a special trash folder set, return it.
Definition: folderstorage.h:387
ExpireUnits getUnreadExpireUnits() const
Units getUnreadExpireAge() is returned in.
Definition: kmfolder.h:461
int addMsgKeepUID(KMMessage *msg, int *index_return=0)
(Note(bo): This needs to be fixed better at a later point.) This is overridden by dIMAP because addMs...
Definition: kmfolder.cpp:395
void setReadExpireAge(int age)
Set the maximum age for read messages in this folder.
Definition: kmfolder.cpp:748
bool needsCompacting() const
Returns TRUE if the folder contains deleted messages.
Definition: folderstorage.h:329
KMFolder * trashFolder() const
If this folder has a special trash folder set, return it.
Definition: kmfolder.cpp:821
void setStatus(int idx, KMMsgStatus status, bool toggle=false)
Set the status of the message at index idx to status.
Definition: kmfolder.cpp:831
void setUnreadExpireAge(int age)
Set the maximum age for unread messages in this folder.
Definition: kmfolder.cpp:733
virtual void setNoContent(bool aNoContent)
Specify, that the folder can't contain mails.
Definition: folderstorage.cpp:1199
virtual KMFolderMgr * manager() const
Returns the folder manager that manages this folder.
Definition: kmfolderdir.cpp:355
virtual int canAccess()=0
Check folder for permissions Returns zero if readable and writable.
void deregisterFromMessageDict()
Triggers deregistration from the message dict, which will cause the dict to ask the FolderStorage to ...
Definition: folderstorage.cpp:970
int expungeOldMsg(int days)
Delete messages in the folder that are older than days.
Definition: kmfolder.cpp:420
TQString idString() const
Returns a string that can be used to identify this folder.
Definition: kmfolder.cpp:705
virtual int addMsgKeepUID(KMMessage *msg, int *index_return=0)
(Note(bo): This needs to be fixed better at a later point.) This is overridden by dIMAP because addMs...
Definition: folderstorage.h:197
virtual TQString indexLocation() const =0
Returns full path to index file.
virtual void updateChildrenState()
Updates the hasChildren() state.
Definition: folderstorage.cpp:1096
virtual KMMsgInfo * unGetMsg(int idx)
Replace KMMessage with KMMsgInfo and delete KMMessage
Definition: folderstorage.cpp:566
virtual int expungeOldMsg(int days)
Delete messages in the folder that are older than days.
Definition: folderstorage.cpp:254
virtual int countUnread()
Number of new or unread messages in this folder.
Definition: folderstorage.cpp:829
void setChild(KMFolderDir *aChild)
Set the folder directory associated with this node.
Definition: kmfolder.cpp:295
virtual bool noChildren() const
Returns, if the folder can't have children.
Definition: folderstorage.h:113
virtual void removeMsg(int i, bool imapQuiet=false)
Remove (first occurrence of) given message from the folder.
Definition: folderstorage.cpp:380
void expireOldMessages(bool immediate)
Expire old messages in this folder.
Definition: kmfolder.cpp:801
void emitMsgAddedSignals(int idx)
Called by derived classes implementation of addMsg.
Definition: folderstorage.cpp:284
bool needsCompacting() const
Returns true if the folder contains deleted messages.
Definition: kmfolder.cpp:546
void readConfig(TDEConfig *config)
This is used by the storage to read the folder specific configuration.
Definition: kmfolder.cpp:161
virtual bool canDeleteMessages() const
Can messages in this folder be deleted?
Definition: folderstorage.cpp:1194
bool isWritable() const
Can we write into and delete from this folder (on IMAP that's not necessarily !isReadOnly())
Definition: kmfolder.cpp:571
A scheduled "compact mails in this folder" task.
Definition: compactionjob.h:101
int moveMsg(KMMessage *msg, int *index_return=0)
Detaches the given message from it's current folder and adds it to this folder.
Definition: kmfolder.cpp:425
virtual void remove()
Removes the folder physically from disk and empties the contents of the folder in memory.
Definition: folderstorage.cpp:755
int getReadExpireAge() const
Get the age at which read messages are expired.
Definition: kmfolder.h:455
int getUnreadExpireAge() const
Get the age at which unread messages are expired.
Definition: kmfolder.h:449
void setNoContent(bool aNoContent)
Specify, that the folder can't contain mails.
Definition: kmfolder.cpp:306
virtual DwString getDwString(int idx)=0
Read a message and returns a DwString.
void numUnreadMsgsChanged(KMFolder *)
Emitted when number of unread messages has changed.
virtual int moveMsg(KMMessage *msg, int *index_return=0)
Detaches the given message from it's current folder and adds it to this folder.
Definition: folderstorage.cpp:621
KMFolder(KMFolderDir *parent, const TQString &name, KMFolderType aFolderType, bool withIndex=true, bool exportedSernums=true)
Constructs a new Folder object.
Definition: kmfolder.cpp:48
bool isSystemFolder() const
Returns true if the folder is a kmail system folder.
Definition: kmfolder.h:369
virtual bool isMessage(int idx)
Checks if the message is already "gotten" with getMsg.
Definition: folderstorage.cpp:591
bool isMessage(int idx)
Checks if the message is already "gotten" with getMsg.
Definition: kmfolder.cpp:331
virtual int rename(const TQString &newName, KMFolderDir *aParent=0)
Physically rename the folder.
Definition: folderstorage.cpp:665
virtual void markUnreadAsRead()
Mark all new and unread messages as read.
Definition: folderstorage.cpp:183
virtual void setStatus(int idx, KMMsgStatus status, bool toggle=false)
Set the status of the message at index idx to status.
Definition: folderstorage.cpp:1043
void removeMsg(int i, bool imapQuiet=false)
Remove (first occurrence of) given message from the folder.
Definition: kmfolder.cpp:410
virtual bool noContent() const
Returns, if the folder can't contain mails, but only subfolder.
Definition: folderstorage.h:107
virtual TQString prettyURL() const
URL of the node for visualization purposes.
Definition: kmfolder.cpp:593
virtual FolderJob * createJob(KMMessage *msg, FolderJob::JobType jt=FolderJob::tGetMessage, KMFolder *folder=0, TQString partSpecifier=TQString(), const AttachmentStrategy *as=0) const
These methods create respective FolderJob (You should derive FolderJob for each derived KMFolder).
Definition: folderstorage.cpp:600
