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 73 of file attachmentpart.cpp.

◆ ~AttachmentPart()

AttachmentPart::~AttachmentPart ( )
virtual

Destroys the attachment part.

Definition at line 78 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 151 of file attachmentpart.cpp.

◆ data()

QByteArray AttachmentPart::data ( ) const

Returns the payload data of the attachment.

Definition at line 201 of file attachmentpart.cpp.

◆ description()

QString AttachmentPart::description ( ) const

Returns the description of the attachment.

Definition at line 103 of file attachmentpart.cpp.

◆ encoding()

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

Returns the encoding that will be used for the attachment.

Definition at line 139 of file attachmentpart.cpp.

◆ fileName()

QString AttachmentPart::fileName ( ) const

Returns the file name of the attachment.

Definition at line 93 of file attachmentpart.cpp.

◆ isAutoEncoding()

bool AttachmentPart::isAutoEncoding ( ) const

Returns whether encoding of the attachment will be determined automatically.

Definition at line 123 of file attachmentpart.cpp.

◆ isCompressed()

bool AttachmentPart::isCompressed ( ) const

Returns whether the attachment is compressed.

Definition at line 171 of file attachmentpart.cpp.

◆ isEncrypted()

bool AttachmentPart::isEncrypted ( ) const

Returns whether the attachment is encrypted.

Definition at line 181 of file attachmentpart.cpp.

◆ isInline()

bool AttachmentPart::isInline ( ) const

Returns whether the attachment will be displayed inline the message.

Definition at line 113 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 222 of file attachmentpart.cpp.

◆ isSigned()

bool AttachmentPart::isSigned ( ) const

Returns whether the attachment is signed.

Definition at line 191 of file attachmentpart.cpp.

◆ mimeType()

QByteArray AttachmentPart::mimeType ( ) const

Returns the mime type of the attachment.

Definition at line 161 of file attachmentpart.cpp.

◆ name()

QString AttachmentPart::name ( ) const

Returns the name of the attachment.

Definition at line 83 of file attachmentpart.cpp.

◆ setAutoEncoding()

void AttachmentPart::setAutoEncoding ( bool  enabled)

Sets whether encoding of the attachment will be determined automatically.

Definition at line 128 of file attachmentpart.cpp.

◆ setCharset()

void AttachmentPart::setCharset ( const QByteArray charset)

Sets the charset that will be used for the attachment.

Definition at line 156 of file attachmentpart.cpp.

◆ setCompressed()

void AttachmentPart::setCompressed ( bool  compressed)

Sets whether the attachment is compressed.

Definition at line 176 of file attachmentpart.cpp.

◆ setData()

void AttachmentPart::setData ( const QByteArray data)

Sets the payload data of the attachment.

Definition at line 206 of file attachmentpart.cpp.

◆ setDescription()

void AttachmentPart::setDescription ( const QString description)

Sets the description of the attachment.

Definition at line 108 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 144 of file attachmentpart.cpp.

◆ setEncrypted()

void AttachmentPart::setEncrypted ( bool  encrypted)

Sets whether the attachment is encrypted.

Definition at line 186 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 98 of file attachmentpart.cpp.

◆ setInline()

void AttachmentPart::setInline ( bool  value)

Sets whether the attachment will be displayed inline the message.

Definition at line 118 of file attachmentpart.cpp.

◆ setMimeType()

void AttachmentPart::setMimeType ( const QByteArray mimeType)

Sets the mimeType of the attachment.

Definition at line 166 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 88 of file attachmentpart.cpp.

◆ setSigned()

void AttachmentPart::setSigned ( bool  sign)

Sets whether the attachment is signed.

Definition at line 196 of file attachmentpart.cpp.

◆ size()

qint64 AttachmentPart::size ( ) const

Returns the size of the attachment.

Definition at line 217 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-2023 The KDE developers.
Generated on Fri Jan 27 2023 07:50:34 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.