1
/* This file is part of KDevelop
2
Copyright 2008 David Nolden <david.nolden.kdevelop@art-master.de>
3
Copyright 2008 Niko Sams <niko.sams@gmail.com>
5
This library is free software; you can redistribute it and/or
6
modify it under the terms of the GNU Library General Public
7
License version 2 as published by the Free Software Foundation.
9
This library is distributed in the hope that it will be useful,
10
but WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12
Library General Public License for more details.
14
You should have received a copy of the GNU Library General Public License
15
along with this library; see the file COPYING.LIB. If not, write to
16
the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17
Boston, MA 02110-1301, USA.
19
#ifndef EXPRESSIONEVALUATIONRESULT_H
20
#define EXPRESSIONEVALUATIONRESULT_H
22
#include "phpduchainexport.h"
23
#include <language/duchain/appendedlist.h>
24
#include <language/duchain/declarationid.h>
25
#include <language/duchain/types/referencetype.h>
26
#include <language/duchain/types/indexedtype.h>
42
class KDEVPHPDUCHAIN_EXPORT ExpressionEvaluationResult
45
ExpressionEvaluationResult();
46
~ExpressionEvaluationResult();
48
void setDeclaration(KDevelop::Declaration* declaration);
49
void setDeclarations(QList<KDevelop::Declaration*> declarations);
50
void setType(KDevelop::AbstractType::Ptr type);
52
KDevelop::AbstractType::Ptr type() const;
53
QList<KDevelop::DeclarationId> allDeclarationIds() const;
54
QList<KDevelop::Declaration*> allDeclarations() const;
57
QList<KDevelop::Declaration*> m_allDeclarations;
58
QList<KDevelop::DeclarationId> m_allDeclarationIds;
59
KDevelop::AbstractType::Ptr m_type; ///Type the expression evaluated to, may be zero when the expression failed to evaluate
61
//bool isInstance; ///Whether the result of this expression is an instance(as it normally should be)
62
//KDevelop::DeclarationId instanceDeclaration; ///If this expression is an instance of some type, this either contains the declaration of the instance, or the type