• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdelibs-4.14.38 API Reference
  • KDE Home
  • Contact Us
 

KDECore

  • kdecore
  • services
kservicetype_p.h
Go to the documentation of this file.
1/* This file is part of the KDE project
2Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
31999 Waldo Bastian <bastian@kde.org>
4
5This library is free software; you can redistribute it and/or
6modify it under the terms of the GNU Library General Public
7License as published by the Free Software Foundation; either
8version 2 of the License, or (at your option) any later version.
9
10This library is distributed in the hope that it will be useful,
11but WITHOUT ANY WARRANTY; without even the implied warranty of
12MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13Library General Public License for more details.
14
15You should have received a copy of the GNU Library General Public License
16along with this library; see the file COPYING.LIB. If not, write to
17the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18Boston, MA 02110-1301, USA.
19*/
20
21#ifndef __kservicetype_p_h__
22#define __kservicetype_p_h__
23
24#include "kservicetype.h"
25#include <ksycocaentry_p.h>
26#include <kurl.h>
27
28class KServiceTypePrivate : public KSycocaEntryPrivate
29{
30public:
31 K_SYCOCATYPE( KST_KServiceType, KSycocaEntryPrivate )
32
33 KServiceTypePrivate(const QString &path)
34 : KSycocaEntryPrivate(path),
35 m_serviceOffersOffset( -1 ), m_bDerived(false), m_parentTypeLoaded(false)
36 {
37 }
38
39 KServiceTypePrivate(QDataStream &_str, int offset)
40 : KSycocaEntryPrivate(_str, offset),
41 m_serviceOffersOffset( -1 ), m_bDerived(false), m_parentTypeLoaded(false)
42 {
43 }
44
45 virtual ~KServiceTypePrivate() {}
46
47 virtual void save( QDataStream& );
48
49 virtual QString name() const
50 {
51 return m_strName;
52 }
53
54 virtual QVariant property(const QString &name) const;
55
56 virtual QStringList propertyNames() const;
57
58 virtual QString comment(const KUrl & = KUrl()) const
59 {
60 return m_strComment;
61 }
62
63 virtual int serviceOffersOffset() const { return m_serviceOffersOffset; }
64
65 void init( KDesktopFile *config );
66 void load(QDataStream& _str);
67
68 KServiceType::Ptr parentType;
69 QString m_strName;
70 mutable /*remove mutable when kmimetype doesn't use this anymore*/ QString m_strComment;
71 int m_serviceOffersOffset;
72 QMap<QString, QVariant::Type> m_mapPropDefs;
73 QMap<QString,QVariant> m_mapProps;
74 unsigned m_bDerived: 1;
75 unsigned m_parentTypeLoaded: 1;
76};
77
78#endif // __kservicetype_p_h__
79
KDesktopFile
KDE Desktop File Management.
Definition: kdesktopfile.h:39
KServiceTypePrivate
Definition: kservicetype_p.h:29
KServiceTypePrivate::propertyNames
virtual QStringList propertyNames() const
Definition: kservicetype.cpp:169
KServiceTypePrivate::m_mapProps
QMap< QString, QVariant > m_mapProps
Definition: kservicetype_p.h:73
KServiceTypePrivate::save
virtual void save(QDataStream &)
Definition: kservicetype.cpp:117
KServiceTypePrivate::comment
virtual QString comment(const KUrl &=KUrl()) const
Definition: kservicetype_p.h:58
KServiceTypePrivate::~KServiceTypePrivate
virtual ~KServiceTypePrivate()
Definition: kservicetype_p.h:45
KServiceTypePrivate::m_bDerived
unsigned m_bDerived
Definition: kservicetype_p.h:74
KServiceTypePrivate::m_strName
QString m_strName
Definition: kservicetype_p.h:69
KServiceTypePrivate::KServiceTypePrivate
KServiceTypePrivate(QDataStream &_str, int offset)
Definition: kservicetype_p.h:39
KServiceTypePrivate::m_mapPropDefs
QMap< QString, QVariant::Type > m_mapPropDefs
Definition: kservicetype_p.h:72
KServiceTypePrivate::m_serviceOffersOffset
int m_serviceOffersOffset
Definition: kservicetype_p.h:71
KServiceTypePrivate::property
virtual QVariant property(const QString &name) const
Definition: kservicetype.cpp:154
KServiceTypePrivate::name
virtual QString name() const
Definition: kservicetype_p.h:49
KServiceTypePrivate::init
void init(KDesktopFile *config)
Definition: kservicetype.cpp:54
KServiceTypePrivate::m_strComment
QString m_strComment
Definition: kservicetype_p.h:70
KServiceTypePrivate::m_parentTypeLoaded
unsigned m_parentTypeLoaded
Definition: kservicetype_p.h:75
KServiceTypePrivate::parentType
KServiceType::Ptr parentType
Definition: kservicetype_p.h:68
KServiceTypePrivate::load
void load(QDataStream &_str)
Definition: kservicetype.cpp:107
KServiceTypePrivate::serviceOffersOffset
virtual int serviceOffersOffset() const
Definition: kservicetype_p.h:63
KSharedPtr< KServiceType >
KSycocaEntryPrivate
Definition: ksycocaentry_p.h:30
KSycocaEntryPrivate::path
QString path
Definition: ksycocaentry_p.h:77
KSycocaEntryPrivate::offset
int offset
Definition: ksycocaentry_p.h:75
KUrl
Represents and parses a URL.
Definition: kurl.h:112
QMap
QStringList
QString
QVariant
kservicetype.h
ksycocaentry_p.h
K_SYCOCATYPE
#define K_SYCOCATYPE(type, baseclass)
Definition: ksycocaentry_p.h:24
KST_KServiceType
@ KST_KServiceType
Definition: ksycocatype.h:31
kurl.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Feb 20 2023 00:00:00 by doxygen 1.9.6 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KDECore

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

kdelibs-4.14.38 API Reference

Skip menu "kdelibs-4.14.38 API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal