CMC_attachment

A CMC_attachment structure contains a CMC message attachment.

Quick Info

Header file: XCMC.H

typedef struct 
{ 
     CMC_string     attach_title; 
     CMC_object_identifier attach_type; 
     CMC_string     attach_filename; 
     CMC_flags attach_flags; 
     CMC_extension FAR     *attach_extensions; 
} CMC_attachment; 
 

Members

attach_title
The optional title for the attachment — for example, the original filename of the attachment.
attach_type
Object identifier that specifies the attachment type. Two attachment types have been defined for use by client applications:
CMC_ATT_OID_BINARY
Data in a file is treated as binary data. This attachment type is the default.
CMC_ATT_OID_TEXT
Data in a file is treated as a text string. This attachment type assumes that data exists in the character set for the session on input and maps to the character set for the session on output, if possible.

A NULL value for attach_type indicates an attachment of an undefined type.

attach_filename
Name of the file in which attachment content is located. The location of the file depends on the CMC implementation, which ensures access by the client application.
attach_flags
Bitmask of flags used to describe attachment options. The following flags can be set:
CMC_ATT_APP_OWNS_FILE
On output, the client application owns the attachment and is responsible for deleting it. This flag is ignored on input. If the flag is not set, it indicates on output that the CMC implementation owns the file and the client application can only read it.
CMC_ATT_LAST_ELEMENT
The last structure in an array of CMC_attachment structures. The structure with this flag set must be at the end of the array. If this flag is set to zero for any structure, that structure is not the last array element.
attach_extensions
Pointer to the first element in an array of CMC_extension structures, each of which is specific to an attachment. Attachment extensions exist to support graphic representation of the attachments in a message when it is displayed. The extensions contain the character positions for the graphic representations. A pointer value of NULL indicates that no extensions are present.

Remarks

A CMC_message structure, which contains information about a CMC message, contains a pointer to an array of one or more CMC_attachment structures defining attachments for the message, or is NULL if there are no attachments. The array elements should have the same order as the attachments in the message, and the last element in the array should have the CMC_ATT_LAST_ELEMENT flag set in its attach_flags member.

See Also

CMC_extension, CMC_message