cdbmodules.h 2.57 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
/**************************************************************************
**
** This file is part of Qt Creator
**
** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
**
** Contact:  Qt Software Information (qt-info@nokia.com)
**
** Commercial Usage
**
** Licensees holding valid Qt Commercial licenses may use this file in
** accordance with the Qt Commercial License Agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Nokia.
**
** 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.
**
** If you are unsure which license is appropriate for your use, please
** contact the sales department at qt-sales@nokia.com.
**
**************************************************************************/

#ifndef CDBMODULES_H
#define CDBMODULES_H

33
#include <QtCore/QStringList>
34

35
#include "cdbcom.h"
36 37 38 39 40

namespace Debugger {
namespace Internal {

class Module;
41
class Symbol;
42

43
bool getModuleList(CIDebugSymbols *syms, QList<Module> *modules, QString *errorMessage);
44 45
bool getModuleNameList(CIDebugSymbols *syms, QStringList *modules, QString *errorMessage);
// Search symbols matching a pattern. Does not filter on module names.
46
bool searchSymbols(CIDebugSymbols *syms, const QString &pattern,
47 48 49 50 51 52 53 54
                   QStringList *matches, QString *errorMessage);

// ResolveSymbol: For symbols that are missing the module specifier,
// find the module and expand: "main" -> "project!main".

enum ResolveSymbolResult { ResolveSymbolOk, ResolveSymbolAmbiguous,
                           ResolveSymbolNotFound, ResolveSymbolError };

55
// Resolve a symbol that is unique to all modules
56
ResolveSymbolResult resolveSymbol(CIDebugSymbols *syms, QString *symbol, QString *errorMessage);
57

58 59 60
// Resolve symbol overload with an additional regexp pattern to filter on modules.
ResolveSymbolResult resolveSymbol(CIDebugSymbols *syms, const QString &pattern, QString *symbol, QString *errorMessage);

61
// List symbols of a module
62
bool getModuleSymbols(CIDebugSymbols *syms, const QString &moduleName,
63 64
                      QList<Symbol> *symbols, QString *errorMessage);

hjk's avatar
hjk committed
65 66
} // namespace Internal
} // namespace Debugger
67 68

#endif // CDBMODULES_H