Add AbstractDeclarationNavigationContext, and move the html-method from
[kdevelopdvcssupport.git] / language / duchain / parsingenvironment.cpp
blob556d7d9d4d9fadc2e61ce913b3a9115d618a4cf2
1 /*
2 Copyright 2007 David Nolden <david.nolden.kdevelop@art-master.de>
4 This library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Library General Public
6 License version 2 as published by the Free Software Foundation.
8 This library is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 Library General Public License for more details.
13 You should have received a copy of the GNU Library General Public License
14 along with this library; see the file COPYING.LIB. If not, write to
15 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16 Boston, MA 02110-1301, USA.
19 #include "parsingenvironment.h"
20 #include "topducontext.h"
21 #include "duchainregister.h"
23 namespace KDevelop
25 // REGISTER_DUCHAIN_ITEM(ParsingEnvironmentFile);
27 TopDUContext::Features ParsingEnvironmentFile::features() const {
28 return d_func()->m_features;
31 void ParsingEnvironmentFile::setFeatures(TopDUContext::Features features) {
32 d_func_dynamic()->m_features = features;
35 ParsingEnvironment::ParsingEnvironment() {
38 ParsingEnvironment::~ParsingEnvironment() {
41 ParsingEnvironmentFile::ParsingEnvironmentFile() : DUChainBase(*new ParsingEnvironmentFileData()) {
42 d_func_dynamic()->setClassId(this);
45 TopDUContext* ParsingEnvironmentFile::topContext() const {
46 return indexedTopContext().data();
49 ParsingEnvironmentFile::~ParsingEnvironmentFile() {
52 ParsingEnvironmentFile::ParsingEnvironmentFile(ParsingEnvironmentFileData& data) : DUChainBase(data) {
55 int ParsingEnvironment::type() const {
56 return StandardParsingEnvironment;
59 int ParsingEnvironmentFile::type() const {
60 return StandardParsingEnvironment;
63 bool ParsingEnvironmentFile::isProxyContext() const {
64 return d_func()->m_isProxyContext;
67 void ParsingEnvironmentFile::setIsProxyContext(bool is) {
68 d_func_dynamic()->m_isProxyContext = is;
71 } //KDevelop