• Skip to content
  • Skip to link menu
KDE 4.3 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

Plasma

package.h

Go to the documentation of this file.
00001 /******************************************************************************
00002 *   Copyright 2007 by Aaron Seigo <aseigo@kde.org>                        *
00003 *   Copyright 2007 by Riccardo Iaconelli <riccardo@kde.org>               *
00004 *                                                                             *
00005 *   This library is free software; you can redistribute it and/or             *
00006 *   modify it under the terms of the GNU Library General Public               *
00007 *   License as published by the Free Software Foundation; either              *
00008 *   version 2 of the License, or (at your option) any later version.          *
00009 *                                                                             *
00010 *   This library is distributed in the hope that it will be useful,           *
00011 *   but WITHOUT ANY WARRANTY; without even the implied warranty of            *
00012 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU          *
00013 *   Library General Public License for more details.                          *
00014 *                                                                             *
00015 *   You should have received a copy of the GNU Library General Public License *
00016 *   along with this library; see the file COPYING.LIB.  If not, write to      *
00017 *   the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,      *
00018 *   Boston, MA 02110-1301, USA.                                               *
00019 *******************************************************************************/
00020 
00021 #ifndef PLASMA_PACKAGE_H
00022 #define PLASMA_PACKAGE_H
00023 
00024 #include <QtCore/QStringList>
00025 
00026 #include <plasma/plasma_export.h>
00027 #include <plasma/packagestructure.h>
00028 
00029 namespace Plasma
00030 {
00031 
00038 class PackageMetadata;
00039 class PackagePrivate;
00040 
00041 class PLASMA_EXPORT Package
00042 {
00043     public:
00051         Package(const QString &packageRoot, const QString &package,
00052                 PackageStructure::Ptr structure);
00053 
00060         Package(const QString &packagePath, PackageStructure::Ptr structure);
00061 
00062         ~Package();
00063 
00068         bool isValid() const;
00069 
00078         QString filePath(const char *fileType, const QString &filename) const;
00079 
00088         QString filePath(const char *fileType) const;
00089 
00097         QStringList entryList(const char *fileType) const;
00098 
00102         PackageMetadata metadata() const;
00103 
00109         void setPath(const QString &path);
00110 
00114         const QString path() const;
00115 
00119         const PackageStructure::Ptr structure() const;
00120 
00128         static QStringList listInstalled(const QString &packageRoot);
00129 
00137         static QStringList listInstalledPaths(const QString &packageRoot);
00138 
00151         static bool installPackage(const QString &package,
00152                                    const QString &packageRoot,
00153                                    const QString &servicePrefix);
00154 
00165         static bool uninstallPackage(const QString &package,
00166                                      const QString &packageRoot,
00167                                      const QString &servicePrefix);
00168 
00175         static bool registerPackage(const PackageMetadata &data, const QString &iconPath);
00176 
00187         static bool createPackage(const PackageMetadata &metadata,
00188                                   const QString &source,
00189                                   const QString &destination,
00190                                   const QString &icon = QString());
00191 
00192     private:
00193         Q_DISABLE_COPY(Package)
00194         PackagePrivate * const d;
00195 };
00196 
00197 } // Namespace
00198 
00199 #endif
00200 

Plasma

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

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.6.1
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal