class CCalAttachment : public CBase |
Class representing a calendar attachment. This allows access to the attachment content itself and associated metadata.
This can be either a URI (RFC 3986) or a file attachment, which must be specified on creation. A URI attachment requires a descriptor containing the URI. A file attachment can be specified as either a descriptor containing the binary data or as a file handle.
Attachment data (i.e. URI, binary data) cannot be changed once an attachment has been created. This does not include metadata properties that are modifiable through the CCalAttachment APIs.
File attachments may also have only a content ID on creation. This applies in cases where a vCalendar or iCalendar (RFC 2445) is imported as part of a message. The content ID refers to the attachment file located elsewhere in the message. The attachment data must be set using CCalAttachment::SetResourceL before the attachment can be stored. The content ID can be changed once it has been set. There is more information about content IDs in the MIME specification (RFC2045).
Public Member Functions | |
---|---|
~CCalAttachment() | |
IMPORT_C void | ClearAttribute(TUint16) |
IMPORT_C CCalAttachmentFile * | FileAttachment() |
CAgnAttachment & | Impl() |
IMPORT_C TBool | IsAttributeSet(TUint16) |
IMPORT_C const TDesC & | Label() |
IMPORT_C const TDesC8 & | MimeType() |
IMPORT_C CCalAttachment * | NewFileByContentIdL(const TDesC8 &) |
IMPORT_C CCalAttachment * | NewFileL(TDesC8 *) |
IMPORT_C CCalAttachment * | NewFileL(RFile &) |
CCalAttachment * | NewL(CAgnAttachment &, CCalSessionImpl &) |
IMPORT_C CCalAttachment * | NewUriL(const TDesC8 &) |
IMPORT_C void | SetAttribute(TUint16) |
IMPORT_C void | SetLabelL(const TDesC &) |
IMPORT_C void | SetMimeTypeL(const TDesC8 &) |
IMPORT_C TType | Type() |
IMPORT_C const TDesC8 & | Value() |
Private Member Functions | |
---|---|
CCalAttachment() | |
CCalAttachment(CAgnAttachment &) | |
void | ConstructL(TType, TDesC8 *) |
void | CreateFileAttachmentImplIfRequiredL(CCalSessionImpl *) |
Public Member Enumerations | |
---|---|
enum | TAttributes { EExportInline = 0x0001 } |
enum | TType { EUri, EFile } |
Private Attributes | |
---|---|
CAgnAttachment * | iAttachmentImpl |
CCalAttachmentFile * | iFileAttachment |
CCalAttachment | ( | CAgnAttachment & | aAttachment | ) | [private] |
CAgnAttachment & aAttachment |
void | CreateFileAttachmentImplIfRequiredL | ( | CCalSessionImpl * | aSessionImpl | ) | [private] |
CCalSessionImpl * aSessionImpl |
IMPORT_C TBool | IsAttributeSet | ( | TUint16 | aAttribute | ) | const |
TUint16 aAttribute |
IMPORT_C CCalAttachment * | NewFileByContentIdL | ( | const TDesC8 & | aContentId | ) | [static] |
const TDesC8 & aContentId |
IMPORT_C CCalAttachment * | NewFileL | ( | TDesC8 * | aBinaryData | ) | [static] |
TDesC8 * aBinaryData |
IMPORT_C CCalAttachment * | NewFileL | ( | RFile & | aFileHandle | ) | [static] |
RFile & aFileHandle |
CCalAttachment * | NewL | ( | CAgnAttachment & | aAttachment, |
CCalSessionImpl & | aSessionImpl | |||
) | [static] |
CAgnAttachment & aAttachment | |
CCalSessionImpl & aSessionImpl |
IMPORT_C CCalAttachment * | NewUriL | ( | const TDesC8 & | aUri | ) | [static] |
const TDesC8 & aUri |
IMPORT_C void | SetMimeTypeL | ( | const TDesC8 & | aContentMimeType | ) |
const TDesC8 & aContentMimeType |
Calendar attachment attributes. Note that the first 8 bits of this enumeration (up to 0x0080) are reserved for future use.
EExportInline = 0x0001 |
If the EExportInline flag is set on a file attachment then it will be exported inline as binary data. Note that, by default:
|
Calendar attachment type.
EUri |
A URI or link to an attachment, e.g. a file or HTTP server address. |
EFile |
A file attachment to be stored in the calendar, either binary data or a file handle. |