MessageCore::AttachmentPart

Search for usage in LXR

MessageCore::AttachmentPart Class Reference

#include <attachmentpart.h>

Public Types

using List = QList< Ptr >
 
using Ptr = QSharedPointer< AttachmentPart >
 

Public Member Functions

 AttachmentPart ()
 
virtual ~AttachmentPart ()
 
QByteArray charset () const
 
QByteArray data () const
 
QString description () const
 
KMime::Headers::contentEncoding encoding () const
 
QString fileName () const
 
bool isAutoEncoding () const
 
bool isCompressed () const
 
bool isEncrypted () const
 
bool isInline () const
 
bool isMessageOrMessageCollection () const
 
bool isSigned () const
 
QByteArray mimeType () const
 
QString name () const
 
void setAutoEncoding (bool enabled)
 
void setCharset (const QByteArray &charset)
 
void setCompressed (bool compressed)
 
void setData (const QByteArray &data)
 
void setDescription (const QString &description)
 
void setEncoding (KMime::Headers::contentEncoding encoding)
 
void setEncrypted (bool encrypted)
 
void setFileName (const QString &name)
 
void setInline (bool value)
 
void setMimeType (const QByteArray &mimeType)
 
void setName (const QString &name)
 
void setSigned (bool sign)
 
void setUrl (const QUrl &url)
 
qint64 size () const
 
QUrl url () const
 

Detailed Description

A class that encapsulates an attachment.

Author
Constantin Berzan exit3[email protected][email protected][email protected]gmail[email protected].com

Definition at line 25 of file attachmentpart.h.

Member Typedef Documentation

◆ List

Defines a list of pointers to attachment objects.

Definition at line 36 of file attachmentpart.h.

◆ Ptr

Defines a pointer to an attachment object.

Definition at line 31 of file attachmentpart.h.

Constructor & Destructor Documentation

◆ AttachmentPart()

AttachmentPart::AttachmentPart ( )

Creates a new attachment part.

Definition at line 74 of file attachmentpart.cpp.

◆ ~AttachmentPart()

AttachmentPart::~AttachmentPart ( )
virtual

Destroys the attachment part.

Definition at line 79 of file attachmentpart.cpp.

Member Function Documentation

◆ charset()

QByteArray AttachmentPart::charset ( ) const

Returns the charset that will be used for the attachment.

Definition at line 152 of file attachmentpart.cpp.

◆ data()

QByteArray AttachmentPart::data ( ) const

Returns the payload data of the attachment.

Definition at line 202 of file attachmentpart.cpp.

◆ description()

QString AttachmentPart::description ( ) const

Returns the description of the attachment.

Definition at line 104 of file attachmentpart.cpp.

◆ encoding()

KMime::Headers::contentEncoding AttachmentPart::encoding ( ) const

Returns the encoding that will be used for the attachment.

Definition at line 140 of file attachmentpart.cpp.

◆ fileName()

QString AttachmentPart::fileName ( ) const

Returns the file name of the attachment.

Definition at line 94 of file attachmentpart.cpp.

◆ isAutoEncoding()

bool AttachmentPart::isAutoEncoding ( ) const

Returns whether encoding of the attachment will be determined automatically.

Definition at line 124 of file attachmentpart.cpp.

◆ isCompressed()

bool AttachmentPart::isCompressed ( ) const

Returns whether the attachment is compressed.

Definition at line 172 of file attachmentpart.cpp.

◆ isEncrypted()

bool AttachmentPart::isEncrypted ( ) const

Returns whether the attachment is encrypted.

Definition at line 182 of file attachmentpart.cpp.

◆ isInline()

bool AttachmentPart::isInline ( ) const

Returns whether the attachment will be displayed inline the message.

Definition at line 114 of file attachmentpart.cpp.

◆ isMessageOrMessageCollection()

bool AttachmentPart::isMessageOrMessageCollection ( ) const

Returns whether the specified attachment part is an encapsulated message (message/rfc822) or a collection of encapsulated messages (multipart/digest)

Definition at line 223 of file attachmentpart.cpp.

◆ isSigned()

bool AttachmentPart::isSigned ( ) const

Returns whether the attachment is signed.

Definition at line 192 of file attachmentpart.cpp.

◆ mimeType()

QByteArray AttachmentPart::mimeType ( ) const

Returns the mime type of the attachment.

Definition at line 162 of file attachmentpart.cpp.

◆ name()

QString AttachmentPart::name ( ) const

Returns the name of the attachment.

Definition at line 84 of file attachmentpart.cpp.

◆ setAutoEncoding()

void AttachmentPart::setAutoEncoding ( bool  enabled)

Sets whether encoding of the attachment will be determined automatically.

Definition at line 129 of file attachmentpart.cpp.

◆ setCharset()

void AttachmentPart::setCharset ( const QByteArray charset)

Sets the charset that will be used for the attachment.

Definition at line 157 of file attachmentpart.cpp.

◆ setCompressed()

void AttachmentPart::setCompressed ( bool  compressed)

Sets whether the attachment is compressed.

Definition at line 177 of file attachmentpart.cpp.

◆ setData()

void AttachmentPart::setData ( const QByteArray data)

Sets the payload data of the attachment.

Definition at line 207 of file attachmentpart.cpp.

◆ setDescription()

void AttachmentPart::setDescription ( const QString description)

Sets the description of the attachment.

Definition at line 109 of file attachmentpart.cpp.

◆ setEncoding()

void AttachmentPart::setEncoding ( KMime::Headers::contentEncoding  encoding)

Sets the encoding that will be used for the attachment.

Note
only applies if isAutoEncoding is false

Definition at line 145 of file attachmentpart.cpp.

◆ setEncrypted()

void AttachmentPart::setEncrypted ( bool  encrypted)

Sets whether the attachment is encrypted.

Definition at line 187 of file attachmentpart.cpp.

◆ setFileName()

void AttachmentPart::setFileName ( const QString name)

Sets the file name of the attachment.

The name will be used in the 'filename=' part of the Content-Disposition header.

Definition at line 99 of file attachmentpart.cpp.

◆ setInline()

void AttachmentPart::setInline ( bool  value)

Sets whether the attachment will be displayed inline the message.

Definition at line 119 of file attachmentpart.cpp.

◆ setMimeType()

void AttachmentPart::setMimeType ( const QByteArray mimeType)

Sets the mimeType of the attachment.

Definition at line 167 of file attachmentpart.cpp.

◆ setName()

void AttachmentPart::setName ( const QString name)

Sets the name of the attachment.

The name will be used in the 'name=' part of the Content-Type header.

Definition at line 89 of file attachmentpart.cpp.

◆ setSigned()

void AttachmentPart::setSigned ( bool  sign)

Sets whether the attachment is signed.

Definition at line 197 of file attachmentpart.cpp.

◆ size()

qint64 AttachmentPart::size ( ) const

Returns the size of the attachment.

Definition at line 218 of file attachmentpart.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Fri Jul 1 2022 05:12:02 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.