CWConstants.h


Use the links in the table of contents to the left to access the documentation.

Includes <GNUstepBase/NSDebug+GNUstepBase.h>, <Pantomime/CWMacOSXGlue.h>


Typedefs

PantomimeContentDisposition

Valid modes when setting a Content-Disposition.

PantomimeEncoding

Supported encodings.

PantomimeFlag

Valid message flags.

PantomimeFolderFormat

The supported folder formats.

PantomimeFolderMode

Valid modes for folder.

PantomimeFolderType

Flags/name attributes for mailboxes/folders.

PantomimeForwardMode

Valid modes when forwarding a message.

PantomimeMessageFormat

The format of a message.

PantomimeRecipientType

Valid recipient types.

PantomimeReplyMode

Valid modes when replying to a message.

PantomimeSearchMask

Mask for Folder: -search: mask: options:

PantomimeSearchOption

Options for Folder: -search: mask: options:

PantomimSearchOption

Options for Folder: -search: mask: options:


PantomimeContentDisposition


Valid modes when setting a Content-Disposition.

typedef enum { 
    PantomimeAttachmentDisposition = 1, 
    PantomimeInlineDisposition = 2 
} PantomimeContentDisposition;  
Constants
PantomimeAttachmentDisposition

The part is separated from the mail body.

PantomimeInlineDisposition

The part is part of the mail body.

Discussion

This enum lists the valid Content-Disposition as stated in the RFC2183 standard.


PantomimeEncoding


Supported encodings.

typedef enum { 
    PantomimeEncodingNone = 0, 
    PantomimeEncoding7bit = 0, 
    PantomimeEncodingQuotedPrintable = 1, 
    PantomimeEncodingBase64 = 2, 
    PantomimeEncoding8bit = 3, 
    PantomimeEncodingBinary = 4 
} PantomimeEncoding;  
Constants
PantomimeEncodingNone

No encoding.

PantomimeEncoding7bit

No encoding, same value as PantomimeEncodingNone.

PantomimeEncodingQuotedPrintable

The quoted-printable encoding.

PantomimeEncodingBase64

The base64 encoding.

PantomimeEncoding8bit

Identity encoding.

PantomimeEncodingBinary

Identity encoding.

Discussion

This enum lists the supported Content-Transfer-Encoding values. See RFC 2045 - 6. Content-Transfer-Encoding Header Field (all all sub-sections) for a detailed description of the possible values.


PantomimeFlag


Valid message flags.

typedef enum { 
    PantomimeAnswered = 1, 
    PantomimeDraft = 2, 
    PantomimeFlagged = 4, 
    PantomimeRecent = 8, 
    PantomimeSeen = 16, 
    PantomimeDeleted = 32 
} PantomimeFlag;  
Constants
PantomimeAnswered

The message has been answered.

PantomimeDraft

The message is an unsent, draft message.

PantomimeFlagged

The message is flagged.

PantomimeRecent

The message has been recently received.

PantomimeSeen

The message has been read.

PantomimeDeleted

The message is marked as deleted.

Discussion

This enum lists valid message flags. Flags can be combined using a bitwise OR.


PantomimeFolderFormat


The supported folder formats.

typedef enum { 
    PantomimeFormatMbox = 0, 
    PantomimeFormatMaildir = 1, 
    PantomimeFormatMailSpoolFile = 2, 
    PantomimeFormatFolder = 3 
} PantomimeFolderFormat;  
Constants
PantomimeFormatMbox

The mbox format.

PantomimeFormatMaildir

The maildir format.

PantomimeFormatMailSpoolFile

The mail spool file, in mbox format but without cache synchronization.

PantomimeFormatFolder

Custom format.

Discussion

Pantomime supports various local folder formats. Currently, the mbox and maildir formats are supported. Also, a custom format is defined to represent folder which holds folders (ie., not messages).


PantomimeFolderMode


Valid modes for folder.

typedef enum { 
    PantomimeUnknownMode = 1, 
    PantomimeReadOnlyMode = 2, 
    PantomimeReadWriteMode = 3 
} PantomimeFolderMode;  
Constants
PantomimeUnknownMode

Unknown mode.

PantomimeReadOnlyMode

The folder will be open in read-only.

PantomimeReadWriteMode

The folder will be open in read-write.

Discussion

This enum lists the valid mode to be used when opening a folder.


PantomimeFolderType


Flags/name attributes for mailboxes/folders.

typedef enum { 
    PantomimeHoldsFolders = 1, 
    PantomimeHoldsMessages = 2, 
    PantomimeNoInferiors = 4, 
    PantomimeNoSelect = 8, 
    PantomimeMarked = 16, 
    PantomimeUnmarked = 32 
} PantomimeFolderType;  
Constants
PantomimeHoldsFolders

The folder holds folders.

PantomimeHoldsMessages

The folder holds messages.

PantomimeNoInferiors

The folder has no sub-folders.

PantomimeNoSelect

The folder can't be opened.

PantomimeMarked

The folder is marked as "interesting".

PantomimeUnmarked

The folder does not contain any new messages since the last time it has been open.

Discussion

This enum lists the potential mailbox / folder flags which some IMAP servers can enforce. Those flags have few meaning for POP3 and Local mailboxes. Flags can be combined using a bitwise OR.


PantomimeForwardMode


Valid modes when forwarding a message.

typedef enum { 
    PantomimeAttachmentForwardMode = 1, 
    PantomimeInlineForwardMode = 2 
} PantomimeForwardMode;  
Constants
PantomimeAttachmentForwardMode

The message will be attached.

PantomimeInlineForwardMode

The text parts of the message will be extracted and included inline in the forwarded response.

Discussion

This enum lists the valid mode to be used when forwarding a message.


PantomimeMessageFormat


The format of a message.

typedef enum { 
    PantomimeFormatUnknown = 0, 
    PantomimeFormatFlowed = 1 
} PantomimeMessageFormat;  
Constants
PantomimeFormatUnknown

Unknown format.

PantomimeFormatFlowed

The "format=flowed" is used.

Discussion

Pantomime supports two formats when encoding plain/text parts. The formats are described in RFC 2646.


PantomimeRecipientType


Valid recipient types.

typedef enum { 
    PantomimeToRecipient = 1, 
    PantomimeCcRecipient = 2, 
    PantomimeBccRecipient = 3, 
    PantomimeResentToRecipient = 4, 
    PantomimeResentCcRecipient = 5, 
    PantomimeResentBccRecipient = 6 
} PantomimeRecipientType;  
Constants
PantomimeToRecipient

Recipient which will appear in the "To:" header value.

PantomimeCcRecipient

Recipient which will appear in the "Cc:" header value.

PantomimeBccRecipient

Recipient which will obtain a black carbon copy of the message.

PantomimeResentToRecipient

Recipient which will appear in the "Resent-To:" header value.

PantomimeResentCcRecipient

Recipient which will appear in the "Resent-Cc:" header value.

PantomimeResentBccRecipient

Recipient which will obtain a black carbon copy of the message being redirected.

Discussion

This enum lists the valid kind of recipients a message can have.


PantomimeReplyMode


Valid modes when replying to a message.

typedef enum { 
    PantomimeSimpleReplyMode = 1, 
    PantomimeNormalReplyMode = 2, 
    PantomimeReplyAllMode = 4 
} PantomimeReplyMode;  
Constants
PantomimeSimpleReplyMode

Reply to the sender, without a message content

PantomimeNormalReplyMode

Reply to the sender, with a properly build message content.

PantomimeReplyAllMode

Reply to all recipients.

Discussion

This enum lists the valid modes to be used when replying to a message. Those modes are to be used with CWMessage: -reply: PantomimeSimpleReplyMode and PantomimeNormalReplyMode can NOT be combined but can be individually combined with PantomimeReplyAllMode.


PantomimeSearchMask


Mask for Folder: -search: mask: options:

typedef enum { 
    PantomimeFrom = 1, 
    PantomimeTo = 2, 
    PantomimeSubject = 4, 
    PantomimeContent = 8 
} PantomimeSearchMask;  
Constants
PantomimeFrom

Search in the "From:" header value.

PantomimeTo

Search in the "To:" header value.

PantomimeSubject

Search in the "Subject:" header value.

PantomimeContent

Search in the message content.

Discussion

This enum lists the possible values of the search mask. Values can be combined using a bitwise OR.


PantomimeSearchOption


Options for Folder: -search: mask: options:

typedef enum { 
    PantomimeCaseInsensitiveSearch = 1, 
    PantomimeRegularExpression = 2 
} PantomimeSearchOption;  
Constants
PantomimeCaseInsensitiveSearch

Don't consider the case when performing a search operation.

PantomimeRegularExpression

The search criteria represents a regular expression.

Discussion

This enum lists the possible options when performing a search.

See Also

PantomimSearchOption


PantomimSearchOption


Options for Folder: -search: mask: options:

typedef enum { 
    PantomimeCaseInsensitiveSearch = 1, 
    PantomimeRegularExpression = 2 
} PantomimeSearchOption;  
Constants
PantomimeCaseInsensitiveSearch

Don't consider the case when performing a search operation.

PantomimeRegularExpression

The search criteria represents a regular expression.

Discussion

This enum lists the possible options when performing a search.

See Also

PantomimeSearchOption


Macro Definitions

_
_Pantomime_H_CWConstants
ASSIGN
AUTHENTICATION_COMPLETED
AUTHENTICATION_FAILED
AUTORELEASE
DESTROY
NSDebugLog
NSDebugLog
NSInteger
NSLocalizedString
NSUInteger
PANTOMIME_VERSION
PERFORM_SELECTOR_1
PERFORM_SELECTOR_2
PERFORM_SELECTOR_3
POST_NOTIFICATION
RELEASE
RETAIN
TEST_RELEASE

_


#define _(X) [[NSBundle mainBundle] localizedStringForKey:(X) value:@"" table:nil] 

_Pantomime_H_CWConstants


#define _Pantomime_H_CWConstants 

ASSIGN


#define ASSIGN(object,value)                 

AUTHENTICATION_COMPLETED


#define AUTHENTICATION_COMPLETED(del, s) \ 
    POST_NOTIFICATION(PantomimeAuthenticationCompleted, self, [NSDictionary dictionaryWithObject: ((id)s?(id)s:(id)@"") forKey: @"Mechanism"]); \ 
    if (del && [del respondsToSelector: @selector(authenticationCompleted:)]) \ 
    { \ 
    [del performSelector: @selector(authenticationCompleted:) \ 
    withObject: [NSNotification notificationWithName: PantomimeAuthenticationCompleted \ 
    object: self \ 
    userInfo: [NSDictionary dictionaryWithObject: ((id)s?(id)s:(id)@"") forKey: @"Mechanism"]]]; \ 
    }; 

AUTHENTICATION_FAILED


#define AUTHENTICATION_FAILED(del, s) \ 
    NSLog(@"POST_NOTIFICATION(PantomimeAuthenticationFailed, self, [NSDictionary dictionaryWithObject: ((id)s?(id)s:(id)@"") forKey: @"Mechanism"]); \ 
    if (del && [del respondsToSelector: @selector(authenticationFailed:)]) \ 
    { \ 
    [del performSelector: @selector(authenticationFailed:) \ 
    withObject: [NSNotification notificationWithName: PantomimeAuthenticationFailed \ 
    object: self \ 
    userInfo: [NSDictionary dictionaryWithObject: ((id)s?(id)s:(id)@"") forKey: @"Mechanism"]]]; \ 
    }; 

AUTORELEASE


#define AUTORELEASE(object) [object autorelease] 

DESTROY


#define DESTROY(object)         

NSDebugLog


#define NSDebugLog(format, args...) \ 
    do { NSLog(format, ##args); } while(0) 

NSDebugLog


#define NSDebugLog(format, args...) 

NSInteger


#define NSInteger int 

NSLocalizedString


#define NSLocalizedString(key, comment) \ 
    [[NSBundle mainBundle] localizedStringForKey:(key) value:@"" table:nil] 

NSUInteger


#define NSUInteger unsigned int 

PANTOMIME_VERSION


 // 
// The current version of Pantomime. 
// 
#define PANTOMIME_VERSION @"1.3.0" 

PERFORM_SELECTOR_1


 // 
// Some macros, to minimize the code. 
// 
#define PERFORM_SELECTOR_1(del, sel, name)                 

PERFORM_SELECTOR_2


#define PERFORM_SELECTOR_2(del, sel, name, obj, key) \ 
    if (del && [del respondsToSelector: sel]) \ 
    { \ 
    [del performSelector: sel \ 
    withObject: [NSNotification notificationWithName: name \ 
    object: self \ 
    userInfo: [NSDictionary dictionaryWithObject: obj forKey: key]]]; \ 
    } 

PERFORM_SELECTOR_3


#define PERFORM_SELECTOR_3(del, sel, name, info) \ 
    if (del && [del respondsToSelector: sel]) \ 
    { \ 
    [del performSelector: sel \ 
    withObject: [NSNotification notificationWithName: name \ 
    object: self \ 
    userInfo: info]]; \ 
    } 

POST_NOTIFICATION


#define POST_NOTIFICATION(name, obj, info) \ 
    [[NSNotificationCenter defaultCenter] postNotificationName: name \ 
    object: obj \ 
    userInfo: info] 

RELEASE


#define RELEASE(object) [object release] 

RETAIN


#define RETAIN(object) [object retain] 

TEST_RELEASE


#define TEST_RELEASE(object)