src/messaging/qmessage_stub.cpp
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Mon, 04 Oct 2010 01:37:06 +0300
changeset 5 603d3f8b6302
parent 0 876b1a06bc25
permissions -rw-r--r--
Revision: 201037 Kit: 201039

/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of the Qt Mobility Components.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
** This file contains pre-release code and may not be distributed.
** You may use this file in accordance with the terms and conditions
** contained in the Technology Preview License Agreement accompanying
** this package.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file.  Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, Nokia gives you certain additional
** rights.  These rights are described in the Nokia Qt LGPL Exception
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
**
** If you have questions regarding the use of this file, please contact
** Nokia at qt-info@nokia.com.
**
**
**
**
**
**
**
**
** $QT_END_LICENSE$
**
****************************************************************************/
#include "qmessage.h"


QTM_BEGIN_NAMESPACE

QMessage::QMessage()
{
}

QMessage::QMessage(const QMessageId& id)
{
    Q_UNUSED(id)
}

QMessage::QMessage(const QMessage &other)
    :QMessageContentContainer(other)
{
    Q_UNUSED(other)
}

QMessage& QMessage::operator=(const QMessage& other)
{
    Q_UNUSED(other)
    return *this; // stub
}

QMessage::~QMessage()
{
}

QMessageId QMessage::id() const
{
    return QMessageId(); // stub
}

QMessage::Type QMessage::type() const
{
    return NoType; // stub
}

void QMessage::setType(Type t)
{
    Q_UNUSED(t)
}

QMessageAccountId QMessage::parentAccountId() const
{
    return QMessageAccountId(); // stub
}

void QMessage::setParentAccountId(const QMessageAccountId &accountId)
{
    Q_UNUSED(accountId)
}

QMessageFolderId QMessage::parentFolderId() const
{
    return QMessageFolderId(); // stub
}

QMessage::StandardFolder QMessage::standardFolder() const
{
    return QMessage::DraftsFolder; // stub
}

QMessageAddress QMessage::from() const
{
    return QMessageAddress(); // stub
}

void QMessage::setFrom(const QMessageAddress &address)
{
    Q_UNUSED(address)
}

QString QMessage::subject() const
{
    return QString::null; //stub
}

void QMessage::setSubject(const QString &s)
{
    Q_UNUSED(s)
}

QDateTime QMessage::date() const
{
    return date(); // stub
}

void QMessage::setDate(const QDateTime &d)
{
    Q_UNUSED(d)
}

QDateTime QMessage::receivedDate() const
{
    return QDateTime(); // stub
}

void QMessage::setReceivedDate(const QDateTime &d)
{
    Q_UNUSED(d)
}

QMessageAddressList QMessage::to() const
{
    return QMessageAddressList(); // stub
}

void QMessage::setTo(const QMessageAddressList& toList)
{
    Q_UNUSED(toList)
}

void QMessage::setTo(const QMessageAddress& address)
{
    Q_UNUSED(address)
}

QMessageAddressList QMessage::cc() const
{
    return QMessageAddressList(); // stub
}

void QMessage::setCc(const QMessageAddressList& ccList)
{
    Q_UNUSED(ccList)
}

QMessageAddressList QMessage::bcc() const
{
    return QMessageAddressList(); // stub
}

void QMessage::setBcc(const QMessageAddressList& bccList)
{
    Q_UNUSED(bccList)
}

QMessage::StatusFlags QMessage::status() const
{
    return StatusFlags(0); // stub
}

void QMessage::setStatus(QMessage::StatusFlags newStatus)
{
    Q_UNUSED(newStatus)
}

void QMessage::setStatus(QMessage::Status flag, bool set)
{
    Q_UNUSED(flag)
    Q_UNUSED(set)
}

QMessage::Priority QMessage::priority() const
{
    return QMessage::NormalPriority; // stub
}

void QMessage::setPriority(Priority newPriority)
{
    Q_UNUSED(newPriority)
}

int QMessage::size() const
{
    return 0; // stub
}

QMessageContentContainerId QMessage::bodyId() const
{
    // TODO: Example body finding algorithm.
    // If the content type of the message is text, then that is the body
    // otherwise if the first part of the body is text then that is the body.
    
    return QMessageContentContainerId(); // stub
}

void QMessage::setBody(const QString &body, const QByteArray &mimeType)
{
    Q_UNUSED(body)
    Q_UNUSED(mimeType)
}

void QMessage::setBody(QTextStream &in, const QByteArray &mimeType)
{
    Q_UNUSED(in)
    Q_UNUSED(mimeType)
}

QMessageContentContainerIdList QMessage::attachmentIds() const
{
    //    TODO: Example attachment list generation algorithm, message parts are the main issue, maybe 
    //    have to recurse into them, somewhat ambiguous.
    //    Don't recurse, just ignore any body part, see bodyId() for body finding algorithm.
    
    // Implementation note, this should be platform independent.
    return QMessageContentContainerIdList(); // stub
}

void QMessage::appendAttachments(const QStringList &fileNames)
{
    // Implementation note, this should be platform independent.
    Q_UNUSED(fileNames)
}

void QMessage::clearAttachments()
{
    // Implementation note, this should be platform independent.
}

bool QMessage::isModified() const
{
    return false; // stub
}

QMessage QMessage::createResponseMessage(ResponseType type) const
{
    return QMessage(); // stub
}


QTM_END_NAMESPACE