• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • KDevelop Shell Profiles Library
 

KDevelop Shell Profiles Library

  • src
  • profileengine
  • lib
profile.h
1 /***************************************************************************
2  * Copyright (C) 2004 by Alexander Dymo <adymo@kdevelop.org> *
3  * *
4  * This program is free software; you can redistribute it and/or modify *
5  * it under the terms of the GNU Library General Public License as *
6  * published by the Free Software Foundation; either version 2 of the *
7  * License, or (at your option) any later version. *
8  * *
9  * This program 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 *
12  * GNU General Public License for more details. *
13  * *
14  * You should have received a copy of the GNU Library General Public *
15  * License along with this program; if not, write to the *
16  * Free Software Foundation, Inc., *
17  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
18  ***************************************************************************/
19 #ifndef PROFILE_H
20 #define PROFILE_H
21 
22 #include <kurl.h>
23 #include <tqstringlist.h>
24 
30 class Profile {
31 public:
33  struct Entry {
34  Entry() {}
35  Entry(const TQString &_name, bool _derived): name(_name), derived(_derived) {}
36  TQString name;
37  bool derived;
38  };
39  typedef TQValueList<Entry> EntryList;
40 
42  enum List {
43  Properties ,
44  ExplicitEnable ,
45  ExplicitDisable
46  };
47 
48  Profile(Profile *parent, const TQString &name);
49  Profile(Profile *parent, const TQString &name, const TQString &genericName, const TQString &description);
50  ~Profile();
51 
52  TQValueList<Profile*> children() const { return m_children; }
53  Profile *parent() const { return m_parent; }
54 
55  void save();
56  bool remove();
57 
58  TQString name() const { return m_name; }
59  TQString genericName() const { return m_genericName; }
60  TQString description() const { return m_description; }
61 
62  EntryList list(List type);
63 
64  void addEntry(List type, const TQString &value);
65  void removeEntry(List type, const TQString &value);
66  void clearList(List type);
67 
68  bool hasInEntryList(EntryList &list, TQString value);
69 
70  KURL::List resources(const TQString &nameFilter);
71  void addResource(const KURL &url);
72 
73  void detachFromParent();
74 
75 protected:
76  void addChildProfile(Profile *profile);
77  void removeChildProfile(Profile *profile);
78  TQString dirName() const;
79 
80  TQStringList &listByType(List type);
81 
82 private:
83  Profile *m_parent;
84  TQValueList<Profile*> m_children;
85 
86  TQString m_name;
87 
88  TQString m_genericName;
89  TQString m_description;
90 
91  TQStringList m_properties;
92  TQStringList m_explicitEnable;
93  TQStringList m_explicitDisable;
94 };
95 
96 #endif
Profile::List
List
Lists which are held by a profile.
Definition: profile.h:42
Profile::Properties
X-TDevelop-Properties defined for this profile.
Definition: profile.h:43
Profile::ExplicitDisable
A list of explicitly disabled plugins (names).
Definition: profile.h:45
Profile::ExplicitEnable
A list of explicitly enabled plugins (names).
Definition: profile.h:44
Profile
KDevelop profile.
Definition: profile.h:30
Profile::Entry
An entry in the lists that store profile information.
Definition: profile.h:33

KDevelop Shell Profiles Library

Skip menu "KDevelop Shell Profiles Library"
  • Main Page
  • Alphabetical List
  • Class List
  • File List
  • Class Members

KDevelop Shell Profiles Library

Skip menu "KDevelop Shell Profiles Library"
  • buildtools
  •   lib
  •     base
  •     parsers
  •       autotools
  •       qmake
  •     widgets
  •   api
  • languages
  •   lib
  •     debugger
  •     designer_integration
  •     interfaces
  • lib
  •   catalog
  •   interfaces
  •     extensions
  •     external
  •     extras
  •   util
  •   widgets
  •     propeditor
  • parts
  •   documentation
  •     interfaces
  • src
  •   profileengine
  •     lib
Generated for KDevelop Shell Profiles Library by doxygen 1.8.13
This website is maintained by Timothy Pearson.