kitchensync

opiedesktopsyncee.h

00001 /*
00002     This file is part of KitchenSync.
00003 
00004     Copyright (c) 2002 Holger Freyther <zecke@handhelds.org>
00005 
00006     This library is free software; you can redistribute it and/or
00007     modify it under the terms of the GNU Library General Public
00008     License as published by the Free Software Foundation; either
00009     version 2 of the License, or (at your option) any later version.
00010 
00011     This library is distributed in the hope that it will be useful,
00012     but WITHOUT ANY WARRANTY; without even the implied warranty of
00013     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014     Library General Public License for more details.
00015 
00016     You should have received a copy of the GNU Library General Public License
00017     along with this library; see the file COPYING.LIB.  If not, write to
00018     the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00019     Boston, MA 02110-1301, USA.
00020 */
00021 #ifndef KSYNC_OPIE_DESKTOP_SYNCEE
00022 #define KSYNC_OPIE_DESKTOP_SYNCEE
00023 
00024 #include <qstringlist.h>
00025 #include <qstring.h>
00026 
00027 #include <syncee.h>
00028 
00029 namespace KSync {
00030 
00039 class KDE_EXPORT OpieDesktopSyncEntry  : public SyncEntry
00040 {
00041   public:
00042     typedef QPtrList<OpieDesktopSyncEntry> PtrList;
00043 
00044     OpieDesktopSyncEntry( Syncee *parent );
00045     OpieDesktopSyncEntry( const QStringList& category,
00046                           const QString& file,
00047                           const QString& name,
00048                           const QString& type,
00049                           const QString& size, Syncee * );
00050     ~OpieDesktopSyncEntry();
00051     OpieDesktopSyncEntry( const OpieDesktopSyncEntry& );
00052 
00053     QString name() ;
00054     QString file() const;
00055     QString fileType() const;
00056     QString size() const;
00057     QStringList category() const;
00058 
00059     QString type() const;
00060     QString id() ;
00061     QString timestamp();
00062     bool equals( SyncEntry* );
00063     SyncEntry* clone();
00064 
00065   private:
00066     class OpieDesktopSyncEntryPrivate;
00067     OpieDesktopSyncEntryPrivate* d;
00068     QStringList mCategory;
00069     QString mFile;
00070     QString mName;
00071     QString mType;
00072     QString mSize;
00073 };
00074 
00075 class KDE_EXPORT OpieDesktopSyncee : public Syncee
00076 {
00077   public:
00078     OpieDesktopSyncee( Merger* m= 0);
00079     ~OpieDesktopSyncee();
00080 
00081 
00082     void addEntry( SyncEntry* entry );
00083     void removeEntry( SyncEntry* entry);
00084     SyncEntry* firstEntry();
00085     SyncEntry* nextEntry();
00086 
00087     bool writeBackup( const QString & ) { return false; }
00088     bool restoreBackup( const QString & ) { return false; }
00089 
00090   private:
00091     OpieDesktopSyncEntry::PtrList mList;
00092 };
00093 
00094 }
00095 
00096 #endif
KDE Home | KDE Accessibility Home | Description of Access Keys