1 /**************************************************************************
3 ** This file is part of Qt Creator
5 ** Copyright (c) 2011 Nokia Corporation and/or its subsidiary(-ies).
7 ** Author: Frank Osterfeld, KDAB (frank.osterfeld@kdab.com)
9 ** Contact: Nokia Corporation (qt-info@nokia.com)
11 ** No Commercial Usage
13 ** This file contains pre-release code and may not be distributed.
14 ** You may use this file in accordance with the terms and conditions
15 ** contained in the Technology Preview License Agreement accompanying
18 ** GNU Lesser General Public License Usage
20 ** Alternatively, this file may be used under the terms of the GNU Lesser
21 ** General Public License version 2.1 as published by the Free Software
22 ** Foundation and appearing in the file LICENSE.LGPL included in the
23 ** packaging of this file. Please review the following information to
24 ** ensure the GNU Lesser General Public License version 2.1 requirements
25 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
27 ** In addition, as a special exception, Nokia gives you certain additional
28 ** rights. These rights are described in the Nokia Qt LGPL Exception
29 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
31 ** If you have questions regarding the use of this file, please contact
32 ** Nokia at qt-info@nokia.com.
34 **************************************************************************/
38 #include <QtCore/QString>
39 #include <QtCore/QtAlgorithms>
41 using namespace Valgrind;
42 using namespace Valgrind::XmlProtocol;
44 class Frame::Private : public QSharedData {
50 bool operator==(const Private &other) const
53 && object == other.object
54 && functionName == other.functionName
56 && directory == other.directory
57 && line == other.line;
68 Frame::Frame() : d(new Private)
76 Frame::Frame(const Frame &other) :
81 Frame &Frame::operator=(const Frame &other)
88 bool Frame::operator==( const Frame &other ) const
90 return *d == *other.d;
93 bool Frame::operator!=(const Frame &other) const
95 return !(*this == other);
98 void Frame::swap(Frame &other)
103 quint64 Frame::instructionPointer() const
108 void Frame::setInstructionPointer(quint64 ip)
113 QString Frame::object() const
118 void Frame::setObject(const QString &obj)
123 QString Frame::functionName() const
125 return d->functionName;
128 void Frame::setFunctionName(const QString &functionName)
130 d->functionName = functionName;
133 QString Frame::file() const
138 void Frame::setFile(const QString &file)
143 QString Frame::directory() const
148 void Frame::setDirectory(const QString &directory)
150 d->directory = directory;
153 int Frame::line() const
158 void Frame::setLine(int line)