~ubuntu-branches/debian/sid/kdevelop/sid

« back to all changes in this revision

Viewing changes to lib/interfaces/kdevprojectiface.h

  • Committer: Bazaar Package Importer
  • Author(s): Jeremy Lainé
  • Date: 2006-05-23 18:39:42 UTC
  • Revision ID: james.westby@ubuntu.com-20060523183942-hucifbvh68k2bwz7
Tags: upstream-3.3.2
Import upstream version 3.3.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* This file is part of the KDE project
 
2
   Copyright (C) 2005 Ian Reinhart Geiser <geiseri@kde.org>
 
3
   
 
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 as published by the Free Software Foundation; either
 
7
   version 2 of the License, or (at your option) any later version.
 
8
 
 
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.
 
13
 
 
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., 59 Temple Place - Suite 330,
 
17
   Boston, MA 02111-1307, USA.
 
18
*/
 
19
 
 
20
#ifndef KDEVPROJECTIFACE_H
 
21
#define KDEVPROJECTIFACE_H
 
22
 
 
23
#include <dcopobject.h>
 
24
#include <qstringlist.h>
 
25
#include <qmap.h>
 
26
 
 
27
class KDevProject;
 
28
 
 
29
/**
 
30
DCOP Interface for the @ref KDevProject object.
 
31
 
 
32
@author KDevelop Authors
 
33
*/
 
34
class KDevProjectIface : public QObject, public DCOPObject
 
35
{
 
36
  Q_OBJECT
 
37
      K_DCOP
 
38
public:
 
39
  KDevProjectIface(KDevProject *prj);
 
40
 
 
41
    ~KDevProjectIface();
 
42
k_dcop:
 
43
    void openProject(const QString &dirName, const QString &projectName);
 
44
    void closeProject();
 
45
    uint options() const;
 
46
    QString projectDirectory() const;
 
47
    QString projectName() const;
 
48
    QString mainProgram(bool relative = false) const;
 
49
    QString runDirectory() const;
 
50
    QString activeDirectory() const;
 
51
    QString buildDirectory() const;
 
52
    QStringList allFiles() const;
 
53
    QStringList distFiles() const;
 
54
    void addFiles(const QStringList &fileList);
 
55
    void addFile(const QString &fileName);
 
56
    void removeFiles(const QStringList& fileList);
 
57
    void removeFile(const QString &fileName);
 
58
    void changedFiles(const QStringList &fileList);
 
59
    void changedFile(const QString &fileName);
 
60
    bool isProjectFile(const QString &absFileName);
 
61
    QString relativeProjectFile(const QString &absFileName);
 
62
    QStringList symlinkProjectFiles();
 
63
    
 
64
    // Project DOM access
 
65
    QString readEntry(const QString &path, const QString &defaultEntry = QString::null);
 
66
    int readIntEntry(const QString &path, int defaultEntry = 0);
 
67
    bool readBoolEntry(const QString &path, bool defaultEntry = false);
 
68
    QStringList readListEntry(const QString &path, const QString &tag);
 
69
    QMap<QString, QString> readMapEntry(const QString &path);
 
70
    
 
71
    void writeEntry(const QString &path, const QString &value);
 
72
    void writeIntEntry(const QString &path, int value);
 
73
    void writeBoolEntry( const QString &path, bool value);
 
74
    void writeListEntry(const QString &path, const QString &tag, const QStringList &value);
 
75
    void writeMapEntry(const QString& path, const QMap<QString,QString> &map);
 
76
    
 
77
  private:
 
78
    KDevProject *m_prj;
 
79
};
 
80
 
 
81
#endif