• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdeutils
 

tdeutils

  • tdeutils
tdecmoduleinfo.h
1/*
2 Copyright (c) 1999 Matthias Hoelzer-Kluepfel <hoelzer@kde.org>
3 Copyright (c) 2000 Matthias Elter <elter@kde.org>
4 Copyright (c) 2003 Daniel Molkentin <molkentin@kde.org>
5 Copyright (c) 2003 Matthias Kretz <kretz@kde.org>
6
7 This file is part of the KDE project
8
9 This library is free software; you can redistribute it and/or
10 modify it under the terms of the GNU Library General Public
11 License version 2, as published by the Free Software Foundation.
12
13 This library is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 Library General Public License for more details.
17
18 You should have received a copy of the GNU Library General Public License
19 along with this library; see the file COPYING.LIB. If not, write to
20 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21 Boston, MA 02110-1301, USA.
22*/
23
24#ifndef TDECMODULEINFO_H
25#define TDECMODULEINFO_H
26
27#include <kservice.h>
28
29class TQPixmap;
30class TQString;
31class TQStringList;
32
49class TDEUTILS_EXPORT TDECModuleInfo
50{
51
52public:
53
61 TDECModuleInfo(const TQString& desktopFile);
62
70 TDECModuleInfo( KService::Ptr moduleInfo );
71
72
78 TDECModuleInfo( const TDECModuleInfo &rhs );
79
85 TDECModuleInfo();
86
90 TDECModuleInfo &operator=( const TDECModuleInfo &rhs );
91
98 bool operator==( const TDECModuleInfo &rhs ) const;
99
103 bool operator!=( const TDECModuleInfo &rhs ) const;
104
108 ~TDECModuleInfo();
109
113 TQString fileName() const { return _fileName; }
114
118 const TQStringList &keywords() const { return _keywords; }
119
126 TQString factoryName() const;
127
131 TQString moduleName() const { return _name; }
132 // changed from name() to avoid ambiguity with TQObject::name() on multiple inheritance
133
137 KService::Ptr service() const { return _service; }
138
142 TQString comment() const { return _comment; }
143
147 TQString icon() const { return _icon; }
148
152 TQString docPath() const;
153
157 TQString library() const { return _lib; }
158
162 TQString handle() const;
163
168 int weight() const;
169
173 bool needsRootPrivileges() const;
174
179 bool isHiddenByDefault() const TDE_DEPRECATED;
180
181
187 bool needsTest() const;
188
189
190protected:
191
196 void setKeywords(const TQStringList &keyword) { _keywords = keyword; }
197
202 void setName(const TQString &name) { _name = name; }
203
208 void setComment(const TQString &comment) { _comment = comment; }
209
214 void setIcon(const TQString &icon) { _icon = icon; }
215
220 void setLibrary(const TQString &lib) { _lib = lib; }
221
226 void setHandle(const TQString &handle) { _handle = handle; }
227
234 void setWeight(int weight) { _weight = weight; }
235
236
242 void setNeedsTest( bool val );
243
249 void setNeedsRootPrivileges(bool needsRootPrivileges)
250 { _needsRootPrivileges = needsRootPrivileges; }
251
255 void setIsHiddenByDefault(bool isHiddenByDefault)
256 { _isHiddenByDefault = isHiddenByDefault; }
257
262 void setDocPath(const TQString &p) { _doc = p; }
263
268 void loadAll();
269
270private:
271
275 void init(KService::Ptr s);
276
277private:
278
279 // KDE4 These needs to be moved to TDECModuleInfoPrivate
280 TQStringList _keywords;
281 TQString _name, _icon, _lib, _handle, _fileName, _doc, _comment;
282 bool _needsRootPrivileges : 1;
283 bool _isHiddenByDefault : 1;
284 bool _allLoaded : 1;
285 int _weight;
286
287 KService::Ptr _service;
288
289 class TDECModuleInfoPrivate;
290 TDECModuleInfoPrivate *d;
291
292};
293
294#endif // TDECMODULEINFO_H
TDECModuleInfo
A class that provides information about a TDECModule.
Definition: tdecmoduleinfo.h:50
TDECModuleInfo::comment
TQString comment() const
Definition: tdecmoduleinfo.h:142
TDECModuleInfo::setComment
void setComment(const TQString &comment)
Sets the object's name.
Definition: tdecmoduleinfo.h:208
TDECModuleInfo::keywords
const TQStringList & keywords() const
Definition: tdecmoduleinfo.h:118
TDECModuleInfo::icon
TQString icon() const
Definition: tdecmoduleinfo.h:147
TDECModuleInfo::setIsHiddenByDefault
void setIsHiddenByDefault(bool isHiddenByDefault)
Definition: tdecmoduleinfo.h:255
TDECModuleInfo::setIcon
void setIcon(const TQString &icon)
Sets the object's icon.
Definition: tdecmoduleinfo.h:214
TDECModuleInfo::setLibrary
void setLibrary(const TQString &lib)
Set the object's library.
Definition: tdecmoduleinfo.h:220
TDECModuleInfo::library
TQString library() const
Definition: tdecmoduleinfo.h:157
TDECModuleInfo::setWeight
void setWeight(int weight)
Sets the object's weight property which determines in what order modules will be displayed.
Definition: tdecmoduleinfo.h:234
TDECModuleInfo::setHandle
void setHandle(const TQString &handle)
Sets the factory name.
Definition: tdecmoduleinfo.h:226
TDECModuleInfo::setName
void setName(const TQString &name)
Sets the object's name.
Definition: tdecmoduleinfo.h:202
TDECModuleInfo::fileName
TQString fileName() const
Definition: tdecmoduleinfo.h:113
TDECModuleInfo::service
KService::Ptr service() const
Definition: tdecmoduleinfo.h:137
TDECModuleInfo::moduleName
TQString moduleName() const
Definition: tdecmoduleinfo.h:131
TDECModuleInfo::setDocPath
void setDocPath(const TQString &p)
Sets the object's documentation path.
Definition: tdecmoduleinfo.h:262
TDECModuleInfo::setNeedsRootPrivileges
void setNeedsRootPrivileges(bool needsRootPrivileges)
Toggles whether the represented module needs root privileges.
Definition: tdecmoduleinfo.h:249

tdeutils

Skip menu "tdeutils"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

tdeutils

Skip menu "tdeutils"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeutils by doxygen 1.9.4
This website is maintained by Timothy Pearson.