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

tdecore

  • tdecore
tdesycocafactory.h
1/* This file is part of the KDE libraries
2 * Copyright (C) 1999 Waldo Bastian <bastian@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 version 2 as published by the Free Software Foundation;
7 *
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * Library General Public License for more details.
12 *
13 * You should have received a copy of the GNU Library General Public License
14 * along with this library; see the file COPYING.LIB. If not, write to
15 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16 * Boston, MA 02110-1301, USA.
17 **/
18
19#ifndef __tdesycocafactory_h__
20#define __tdesycocafactory_h__
21
22#include "tdesycocatype.h"
23#include "tdesycocaentry.h"
24
25#include <tqdict.h>
26#include <tqptrlist.h>
27class KSycoca;
28class TQStringList;
29class TQString;
30class KSycocaDict;
31class KSycocaResourceList;
32
33typedef TQDict<KSycocaEntry::Ptr> KSycocaEntryDict;
34
39class TDECORE_EXPORT KSycocaFactory
40{
41public:
42 virtual KSycocaFactoryId factoryId() const = 0;
43
44protected: // virtual class
49 KSycocaFactory( KSycocaFactoryId factory_id );
50
51public:
52 virtual ~KSycocaFactory();
53
57 int offset() { return mOffset; }
58
62 KSycocaEntryDict * entryDict() { return m_entryDict; }
63
68 virtual KSycocaEntry *createEntry(const TQString &file, const char *resource) = 0;
69
73 virtual void addEntry(KSycocaEntry *newEntry, const char *resource);
74
79 void removeEntry(KSycocaEntry *newEntry);
80
84 virtual KSycocaEntry *createEntry(int offset)=0;
85
89 KSycocaEntry::List allEntries();
90
102 virtual void save(TQDataStream &str);
103
111 virtual void saveHeader(TQDataStream &str);
112
116 virtual const KSycocaResourceList * resourceList() const { return m_resourceList; }
117
118private:
119 int mOffset;
120
121protected:
122 int m_sycocaDictOffset;
123 int m_beginEntryOffset;
124 int m_endEntryOffset;
125 TQDataStream *m_str;
126
127 KSycocaResourceList *m_resourceList;
128 KSycocaEntryDict *m_entryDict;
129 KSycocaDict *m_sycocaDict;
130protected:
131 virtual void virtual_hook( int id, void* data );
132};
133
137class TDECORE_EXPORT KSycocaFactoryList : public TQPtrList<KSycocaFactory>
138{
139public:
140 KSycocaFactoryList() { }
141};
142
143#endif
KSycocaEntry
Base class for all Sycoca entries.
Definition: tdesycocaentry.h:38
KSycocaFactoryList
This, instead of a typedef, allows to declare "class ..." in header files.
Definition: tdesycocafactory.h:138
KStdAction::save
TDEAction * save(const TQObject *recvr, const char *slot, TDEActionCollection *parent, const char *name=0)

tdecore

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

tdecore

Skip menu "tdecore"
  • 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 tdecore by doxygen 1.9.4
This website is maintained by Timothy Pearson.