Qtopia Home - Classes - Annotated - Functions - Qt Embedded |
|
This is the verbatim text of the syncapp.h include file. It is provided only for illustration; the copyright remains with Trolltech.
/**********************************************************************
** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
**
** This file is part of the Qtopia Environment.
**
** Licensees holding valid Qtopia Developer license may use this
** file in accordance with the Qtopia Developer License Agreement
** provided with the Software.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING
** THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR
** PURPOSE.
**
** email sales@trolltech.com for information about Qtopia License
** Agreements.
**
** Contact info@trolltech.com if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
#ifndef qd__syncappinterface_h
#define qd__syncappinterface_h
#include <private/qcom_p.h>
#include <qstring.h>
#include <qcstring.h>
#include <qvaluelist.h>
#include <qmap.h>
#include <qpair.h>
namespace MergeML { class Record; class Change; }
struct CenterInterface;
// {8F107712-ACFD-11D5-923F-009027BEB262}
#ifndef IID_SyncAppInterface
#define IID_SyncAppInterface QUuid( 0x8f107712, 0xacfd, 0x11d5, 0x92, 0x3f, 0x00, 0x90, 0x27, 0xbe, 0xb2, 0x62)
#endif
struct SyncAppInterface : public QUnknownInterface
{
virtual void start( CenterInterface* ) = 0;
enum MergeAction { AutoMerge, ManualMerge, Conflicting };
virtual MergeAction merge( const MergeML::Change &rec1, const MergeML::Change &rec2,
QValueList<MergeML::Change> &manualMergeOut ) = 0;
virtual bool mergeChangeChange() const = 0;
virtual void done() = 0;
virtual QValueList<MergeML::Record> load( const QString &dataset,
const QString &filename ) const=0;
virtual void save( const QString &dataset, const QString &filename,
const QValueList<MergeML::Record> & ) = 0;
enum FileLocation { Settings, Application, InvalidFileLocation };
/** Returns empty string if dataSet is not supported for load or save
* or the filename without a directory (such as "addressbook.xml")
*/
virtual QPair<QString,FileLocation> fileForDataSet( const QString &dataSet ) const = 0;
virtual QMap<int, int> uniqueness( const QString &dataSet ) const = 0;
virtual QString keyName( const QString &dataset, int key) const = 0;
virtual int key( const QString &dataset, const QString &keyString ) const = 0;
virtual QString palmtopApplicationName() const = 0;
virtual QString name() const = 0;
};
#define nullFileSet QPair<QString,FileLocation>(QString::null, SyncAppInterface::InvalidFileLocation)
#endif
| Copyright © 2001-2004 Trolltech | Trademarks | Qtopia version 2.0.1
|