kitchensync Library API Documentation

syncentry.cpp

00001 /* 00002 This file is part of KitchenSync. 00003 00004 Copyright (c) 2002 Cornelius Schumacher <schumacher@kde.org> 00005 Copyright (c) 2002 Holger Freyther <zecke@handhelds.org> 00006 00007 This library is free software; you can redistribute it and/or 00008 modify it under the terms of the GNU Library General Public 00009 License as published by the Free Software Foundation; either 00010 version 2 of the License, or (at your option) any later version. 00011 00012 This library is distributed in the hope that it will be useful, 00013 but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00015 Library General Public License for more details. 00016 00017 You should have received a copy of the GNU Library General Public License 00018 along with this library; see the file COPYING.LIB. If not, write to 00019 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00020 Boston, MA 02111-1307, USA. 00021 */ 00022 00023 #include <kdebug.h> 00024 00025 #include "syncentry.h" 00026 00027 using namespace KSync; 00028 00029 SyncEntry::SyncEntry( Syncee *sync ) 00030 : mSyncee( sync ), mDontSync( false ) 00031 { 00032 mState = Undefined; 00033 mSyncState = Undefined; 00034 } 00035 00036 SyncEntry::SyncEntry( const SyncEntry &ent ) 00037 { 00038 // kdDebug(5230) << "SyncEntry copy c'tor " << endl; 00039 mState = ent.mState; 00040 mSyncee = ent.mSyncee; 00041 mSyncState = ent.mSyncState; 00042 mDontSync = ent.mDontSync; 00043 } 00044 00045 SyncEntry::~SyncEntry() 00046 { 00047 } 00048 00049 void SyncEntry::setSyncee( Syncee *syncee ) 00050 { 00051 mSyncee = syncee; 00052 } 00053 00054 int SyncEntry::match( SyncEntry* /*entry*/ ) 00055 { 00056 return -2; 00057 } 00058 00059 int SyncEntry::compareTo(SyncEntry* /*entry*/ ) 00060 { 00061 return -2; 00062 } 00063 00064 int SyncEntry::state() const 00065 { 00066 return mState; 00067 } 00068 00069 bool SyncEntry::wasAdded() const 00070 { 00071 return ( mState == Added ); 00072 } 00073 00074 bool SyncEntry::wasModified() const 00075 { 00076 return ( mState == Modified ); 00077 } 00078 00079 bool SyncEntry::wasRemoved() const 00080 { 00081 return ( mState == Removed ); 00082 } 00083 00084 void SyncEntry::setState( int state ) 00085 { 00086 // kdDebug(5230) << "State is " << state << endl; 00087 mState = state; 00088 } 00089 00090 void SyncEntry::setSyncState( int state ) 00091 { 00092 mSyncState = state; 00093 } 00094 00095 int SyncEntry::syncState() const 00096 { 00097 return mSyncState; 00098 } 00099 00100 Syncee *SyncEntry::syncee() 00101 { 00102 return mSyncee; 00103 } 00104 00105 /* not implemented here */ 00106 void SyncEntry::setId( const QString& ) 00107 { 00108 } 00109 00110 bool SyncEntry::mergeWith( SyncEntry * ) 00111 { 00112 return false; 00113 } 00114 00115 void SyncEntry::setDontSync( bool dontSync ) 00116 { 00117 mDontSync = dontSync; 00118 } 00119 00120 bool SyncEntry::dontSync() const 00121 { 00122 return mDontSync; 00123 } 00124 00125 KPIM::DiffAlgo* SyncEntry::diffAlgo( SyncEntry*, SyncEntry* ) 00126 { 00127 return 0; 00128 }
KDE Logo
This file is part of the documentation for kitchensync Library Version 3.3.0.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Fri Aug 27 12:50:50 2004 by doxygen 1.3.8 written by Dimitri van Heesch, © 1997-2003