mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-24 02:42:55 +00:00
various cleanups, mostly help component related
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
093009f3e7
commit
4ac0866a99
63 changed files with 231 additions and 289 deletions
|
@ -8,7 +8,7 @@ components = {
|
|||
'DBus': 'Q_DBUS_EXPORT',
|
||||
'Declarative': 'Q_DECLARATIVE_EXPORT',
|
||||
'Designer': 'QDESIGNER_COMPONENTS_EXPORT|QDESIGNER_EXTENSION_EXPORT|QT_FORMEDITOR_EXPORT|QT_PROPERTYEDITOR_EXPORT|QT_SIGNALSLOTEDITOR_EXPORT|QT_OBJECTINSPECTOR_EXPORT|QT_WIDGETBOX_EXPORT|QT_BUDDYEDITOR_EXPORT|QT_TABORDEREDITOR_EXPORT|QT_TASKMENU_EXPORT',
|
||||
'Help': 'QHELP_EXPORT',
|
||||
'Help': 'Q_HELP_EXPORT',
|
||||
'Multimedia': 'Q_MULTIMEDIA_EXPORT',
|
||||
'Network': 'Q_NETWORK_EXPORT',
|
||||
'Sql': 'Q_SQL_EXPORT',
|
||||
|
@ -17,7 +17,7 @@ components = {
|
|||
'XmlPatterns': 'Q_XMLPATTERNS_EXPORT',
|
||||
'Script': 'Q_SCRIPT_EXPORT',
|
||||
'ScriptTools': 'Q_SCRIPTTOOLS_EXPORT',
|
||||
'Test': 'Q_TESTLIB_EXPORT',
|
||||
'Test': 'Q_TEST_EXPORT',
|
||||
'UiTools': 'QDESIGNER_UILIB_EXPORT',
|
||||
'OpenGL': 'Q_OPENGL_EXPORT',
|
||||
}
|
||||
|
|
|
@ -1818,29 +1818,29 @@ QSysInfo::WinVersion QSysInfo::windowsVersion()
|
|||
|
||||
#ifdef QT_DEBUG
|
||||
{
|
||||
QByteArray override = qgetenv("QT_WINVER_OVERRIDE");
|
||||
if (override.isEmpty())
|
||||
QByteArray winver_override = qgetenv("QT_WINVER_OVERRIDE");
|
||||
if (winver_override.isEmpty())
|
||||
return winver;
|
||||
|
||||
if (override == "Me")
|
||||
if (winver_override == "Me")
|
||||
winver = QSysInfo::WV_Me;
|
||||
if (override == "95")
|
||||
if (winver_override == "95")
|
||||
winver = QSysInfo::WV_95;
|
||||
else if (override == "98")
|
||||
else if (winver_override == "98")
|
||||
winver = QSysInfo::WV_98;
|
||||
else if (override == "NT")
|
||||
else if (winver_override == "NT")
|
||||
winver = QSysInfo::WV_NT;
|
||||
else if (override == "2000")
|
||||
else if (winver_override == "2000")
|
||||
winver = QSysInfo::WV_2000;
|
||||
else if (override == "2003")
|
||||
else if (winver_override == "2003")
|
||||
winver = QSysInfo::WV_2003;
|
||||
else if (override == "XP")
|
||||
else if (winver_override == "XP")
|
||||
winver = QSysInfo::WV_XP;
|
||||
else if (override == "VISTA")
|
||||
else if (winver_override == "VISTA")
|
||||
winver = QSysInfo::WV_VISTA;
|
||||
else if (override == "WINDOWS7")
|
||||
else if (winver_override == "WINDOWS7")
|
||||
winver = QSysInfo::WV_WINDOWS7;
|
||||
else if (override == "WINDOWS8")
|
||||
else if (winver_override == "WINDOWS8")
|
||||
winver = QSysInfo::WV_WINDOWS8;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -1437,6 +1437,11 @@ class QDataStream;
|
|||
# else
|
||||
# define Q_GUI_EXPORT Q_DECL_IMPORT
|
||||
# endif
|
||||
# if defined(QT_BUILD_HELP_LIB)
|
||||
# define Q_HELP_EXPORT Q_DECL_EXPORT
|
||||
# else
|
||||
# define Q_HELP_EXPORT Q_DECL_IMPORT
|
||||
# endif
|
||||
# if defined(QT_BUILD_SQL_LIB)
|
||||
# define Q_SQL_EXPORT Q_DECL_EXPORT
|
||||
# else
|
||||
|
@ -1452,6 +1457,11 @@ class QDataStream;
|
|||
# else
|
||||
# define Q_SVG_EXPORT Q_DECL_IMPORT
|
||||
# endif
|
||||
# if defined(QT_BUILD_TEST_LIB)
|
||||
# define Q_TEST_EXPORT Q_DECL_EXPORT
|
||||
# else
|
||||
# define Q_TEST_EXPORT Q_DECL_IMPORT
|
||||
# endif
|
||||
# if defined(QT_BUILD_DECLARATIVE_LIB)
|
||||
# define Q_DECLARATIVE_EXPORT Q_DECL_EXPORT
|
||||
# else
|
||||
|
@ -1496,9 +1506,11 @@ class QDataStream;
|
|||
# elif defined(QT_DLL) /* use a Qt DLL library */
|
||||
# define Q_CORE_EXPORT Q_DECL_IMPORT
|
||||
# define Q_GUI_EXPORT Q_DECL_IMPORT
|
||||
# define Q_HELP_EXPORT Q_DECL_IMPORT
|
||||
# define Q_SQL_EXPORT Q_DECL_IMPORT
|
||||
# define Q_NETWORK_EXPORT Q_DECL_IMPORT
|
||||
# define Q_SVG_EXPORT Q_DECL_IMPORT
|
||||
# define Q_TEST_EXPORT Q_DECL_IMPORT
|
||||
# define Q_DECLARATIVE_EXPORT Q_DECL_IMPORT
|
||||
# define Q_OPENGL_EXPORT Q_DECL_IMPORT
|
||||
# define Q_MULTIMEDIA_EXPORT Q_DECL_IMPORT
|
||||
|
@ -1523,9 +1535,11 @@ class QDataStream;
|
|||
# if defined(QT_SHARED)
|
||||
# define Q_CORE_EXPORT Q_DECL_EXPORT
|
||||
# define Q_GUI_EXPORT Q_DECL_EXPORT
|
||||
# define Q_HELP_EXPORT Q_DECL_EXPORT
|
||||
# define Q_SQL_EXPORT Q_DECL_EXPORT
|
||||
# define Q_NETWORK_EXPORT Q_DECL_EXPORT
|
||||
# define Q_SVG_EXPORT Q_DECL_EXPORT
|
||||
# define Q_TEST_EXPORT Q_DECL_EXPORT
|
||||
# define Q_DECLARATIVE_EXPORT Q_DECL_EXPORT
|
||||
# define Q_OPENGL_EXPORT Q_DECL_EXPORT
|
||||
# define Q_MULTIMEDIA_EXPORT Q_DECL_EXPORT
|
||||
|
@ -1537,9 +1551,11 @@ class QDataStream;
|
|||
# else
|
||||
# define Q_CORE_EXPORT
|
||||
# define Q_GUI_EXPORT
|
||||
# define Q_HELP_EXPORT
|
||||
# define Q_SQL_EXPORT
|
||||
# define Q_NETWORK_EXPORT
|
||||
# define Q_SVG_EXPORT
|
||||
# define Q_TEST_EXPORT
|
||||
# define Q_DECLARATIVE_EXPORT
|
||||
# define Q_OPENGL_EXPORT
|
||||
# define Q_MULTIMEDIA_EXPORT
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
add_definitions(-DQHELP_LIB -DQT_CLUCENE_SUPPORT)
|
||||
add_definitions(-DQT_BUILD_HELP_LIB -DQT_CLUCENE_SUPPORT)
|
||||
set(EXTRA_HELP_LIBS KtCore KtGui KtNetwork KtSql KtXml)
|
||||
|
||||
include(fulltextsearch/fulltextsearch.cmake)
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qanalyzer_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/analysis/AnalysisHeader.h>
|
||||
|
@ -64,7 +63,7 @@ qint32 QCLuceneAnalyzer::positionIncrementGap(const QString &fieldName) const
|
|||
QCLuceneTokenStream QCLuceneAnalyzer::tokenStream(const QString &fieldName,
|
||||
const QCLuceneReader &reader) const
|
||||
{
|
||||
TCHAR *fName = QStringToTChar(fieldName);
|
||||
TCHAR *fName = QHelp::QStringToTChar(fieldName);
|
||||
QCLuceneTokenStream tokenStream;
|
||||
tokenStream.d->tokenStream = d->analyzer->tokenStream(fName, reader.d->reader);
|
||||
delete [] fName;
|
||||
|
@ -89,7 +88,7 @@ QCLuceneStandardAnalyzer::QCLuceneStandardAnalyzer(const QStringList &stopWords)
|
|||
const TCHAR **tArray = new const TCHAR*[stopWords.count() +1];
|
||||
|
||||
for(int i = 0; i < stopWords.count(); ++i) {
|
||||
TCHAR *stopWord = QStringToTChar(stopWords.at(i));
|
||||
TCHAR *stopWord = QHelp::QStringToTChar(stopWords.at(i));
|
||||
tArray[i] = STRDUP_TtoT(stopWord);
|
||||
delete [] stopWord;
|
||||
}
|
||||
|
@ -145,7 +144,7 @@ QCLuceneStopAnalyzer::QCLuceneStopAnalyzer(const QStringList &stopWords)
|
|||
const TCHAR **tArray = new const TCHAR*[stopWords.count() +1];
|
||||
|
||||
for(int i = 0; i < stopWords.count(); ++i) {
|
||||
TCHAR *stopWord = QStringToTChar(stopWords.at(i));
|
||||
TCHAR *stopWord = QHelp::QStringToTChar(stopWords.at(i));
|
||||
tArray[i] = STRDUP_TtoT(stopWord);
|
||||
delete [] stopWord;
|
||||
}
|
||||
|
@ -165,7 +164,7 @@ QStringList QCLuceneStopAnalyzer::englishStopWords() const
|
|||
|
||||
const TCHAR** stopWords = lucene::analysis::StopAnalyzer::ENGLISH_STOP_WORDS;
|
||||
for (qint32 i = 0; stopWords[i] != 0; ++i)
|
||||
stopWordList.append(TCharToQString(stopWords[i]));
|
||||
stopWordList.append(QHelp::TCharToQString(stopWords[i]));
|
||||
|
||||
return stopWordList;
|
||||
}
|
||||
|
@ -211,7 +210,7 @@ void QCLucenePerFieldAnalyzerWrapper::addAnalyzer(const QString &fieldName,
|
|||
analyzers.append(analyzer);
|
||||
analyzer->d->deleteCLuceneAnalyzer = false;
|
||||
|
||||
TCHAR *fName = QStringToTChar(fieldName);
|
||||
TCHAR *fName = QHelp::QStringToTChar(fieldName);
|
||||
analyzerWrapper->addAnalyzer(fName, analyzer->d->analyzer);
|
||||
delete [] fName;
|
||||
}
|
||||
|
|
|
@ -31,12 +31,10 @@
|
|||
|
||||
#include "qreader_p.h"
|
||||
#include "qtokenstream_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QList>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/QStringList>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(analysis)
|
||||
|
@ -55,7 +53,7 @@ class QCLuceneStandardAnalyzer;
|
|||
class QCLuceneWhitespaceAnalyzer;
|
||||
class QCLucenePerFieldAnalyzerWrapper;
|
||||
|
||||
class QHELP_EXPORT QCLuceneAnalyzerPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneAnalyzerPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneAnalyzerPrivate();
|
||||
|
@ -70,7 +68,7 @@ private:
|
|||
QCLuceneAnalyzerPrivate &operator=(const QCLuceneAnalyzerPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneAnalyzer
|
||||
class Q_HELP_EXPORT QCLuceneAnalyzer
|
||||
{
|
||||
public:
|
||||
virtual ~QCLuceneAnalyzer();
|
||||
|
@ -94,7 +92,7 @@ private:
|
|||
QCLuceneAnalyzer();
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneStandardAnalyzer : public QCLuceneAnalyzer
|
||||
class Q_HELP_EXPORT QCLuceneStandardAnalyzer : public QCLuceneAnalyzer
|
||||
{
|
||||
public:
|
||||
QCLuceneStandardAnalyzer();
|
||||
|
@ -103,21 +101,21 @@ public:
|
|||
~QCLuceneStandardAnalyzer();
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneWhitespaceAnalyzer : public QCLuceneAnalyzer
|
||||
class Q_HELP_EXPORT QCLuceneWhitespaceAnalyzer : public QCLuceneAnalyzer
|
||||
{
|
||||
public:
|
||||
QCLuceneWhitespaceAnalyzer();
|
||||
~QCLuceneWhitespaceAnalyzer();
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneSimpleAnalyzer : public QCLuceneAnalyzer
|
||||
class Q_HELP_EXPORT QCLuceneSimpleAnalyzer : public QCLuceneAnalyzer
|
||||
{
|
||||
public:
|
||||
QCLuceneSimpleAnalyzer();
|
||||
~QCLuceneSimpleAnalyzer();
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneStopAnalyzer : public QCLuceneAnalyzer
|
||||
class Q_HELP_EXPORT QCLuceneStopAnalyzer : public QCLuceneAnalyzer
|
||||
{
|
||||
public:
|
||||
QCLuceneStopAnalyzer();
|
||||
|
@ -128,14 +126,14 @@ public:
|
|||
QStringList englishStopWords() const;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneKeywordAnalyzer : public QCLuceneAnalyzer
|
||||
class Q_HELP_EXPORT QCLuceneKeywordAnalyzer : public QCLuceneAnalyzer
|
||||
{
|
||||
public:
|
||||
QCLuceneKeywordAnalyzer();
|
||||
~QCLuceneKeywordAnalyzer();
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLucenePerFieldAnalyzerWrapper : public QCLuceneAnalyzer
|
||||
class Q_HELP_EXPORT QCLucenePerFieldAnalyzerWrapper : public QCLuceneAnalyzer
|
||||
{
|
||||
public:
|
||||
QCLucenePerFieldAnalyzerWrapper(QCLuceneAnalyzer *defaultAnalyzer);
|
||||
|
|
|
@ -48,14 +48,6 @@ QT_BEGIN_HEADER
|
|||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
#if !defined(QT_SHARED) && !defined(QT_DLL)
|
||||
# define QHELP_EXPORT
|
||||
#elif defined(QHELP_LIB)
|
||||
# define QHELP_EXPORT Q_DECL_EXPORT
|
||||
#else
|
||||
# define QHELP_EXPORT Q_DECL_IMPORT
|
||||
#endif
|
||||
|
||||
//
|
||||
// W A R N I N G
|
||||
// -------------
|
||||
|
@ -63,9 +55,7 @@ QT_BEGIN_NAMESPACE
|
|||
// adjustments here, need to be done in
|
||||
// QTDIR/src/3rdparty/clucene/src/CLucene/StdHeader.h as well
|
||||
//
|
||||
#if defined(_LUCENE_DONTIMPLEMENT_NS_MACROS)
|
||||
|
||||
#elif !defined(DISABLE_NAMESPACE)
|
||||
#if !defined(DISABLE_NAMESPACE)
|
||||
# ifdef QT_NAMESPACE
|
||||
# define CL_NS_DEF(sub) namespace QT_NAMESPACE { namespace lucene{ namespace sub{
|
||||
# define CL_NS_DEF2(sub,sub2) namespace QT_NAMESPACE { namespace lucene{ namespace sub{ namespace sub2 {
|
||||
|
@ -102,8 +92,9 @@ QT_BEGIN_NAMESPACE
|
|||
# define CL_NS2(sub,sub2)
|
||||
#endif
|
||||
|
||||
namespace {
|
||||
TCHAR* QStringToTChar(const QString &str)
|
||||
namespace QHelp
|
||||
{
|
||||
inline TCHAR* QStringToTChar(const QString &str)
|
||||
{
|
||||
TCHAR *string = new TCHAR[(str.length() +1) * sizeof(TCHAR)];
|
||||
memset(string, 0, (str.length() +1) * sizeof(TCHAR));
|
||||
|
@ -116,7 +107,7 @@ namespace {
|
|||
return string;
|
||||
}
|
||||
|
||||
QString TCharToQString(const TCHAR *string)
|
||||
inline QString TCharToQString(const TCHAR *string)
|
||||
{
|
||||
#if defined(UNICODE) || defined(_CL_HAVE_WCHAR_H) && defined(_CL_HAVE_WCHAR_T)
|
||||
QString retValue = QString::fromWCharArray(string);
|
||||
|
|
|
@ -17,7 +17,6 @@
|
|||
|
||||
#include "qdocument_p.h"
|
||||
#include "qreader_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/util/Reader.h>
|
||||
|
@ -75,7 +74,7 @@ QCLuceneField* QCLuceneDocument::getField(const QString &name) const
|
|||
}
|
||||
|
||||
field = 0;
|
||||
TCHAR *fieldName = QStringToTChar(name);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(name);
|
||||
lucene::document::Field *f = d->document->getField(fieldName);
|
||||
if (f) {
|
||||
field = new QCLuceneField();
|
||||
|
@ -105,7 +104,7 @@ QString QCLuceneDocument::get(const QString &name) const
|
|||
|
||||
QString QCLuceneDocument::toString() const
|
||||
{
|
||||
return TCharToQString(d->document->toString());
|
||||
return QHelp::TCharToQString(d->document->toString());
|
||||
}
|
||||
|
||||
void QCLuceneDocument::setBoost(qreal boost)
|
||||
|
@ -120,7 +119,7 @@ qreal QCLuceneDocument::getBoost() const
|
|||
|
||||
void QCLuceneDocument::removeField(const QString &name)
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(name);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(name);
|
||||
d->document->removeField(fieldName);
|
||||
delete [] fieldName;
|
||||
|
||||
|
@ -147,20 +146,20 @@ void QCLuceneDocument::removeFields(const QString &name)
|
|||
delete fieldList.takeAt(i);
|
||||
}
|
||||
|
||||
TCHAR *fieldName = QStringToTChar(name);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(name);
|
||||
d->document->removeFields(fieldName);
|
||||
delete [] fieldName;
|
||||
}
|
||||
|
||||
QStringList QCLuceneDocument::getValues(const QString &name) const
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(name);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(name);
|
||||
TCHAR **values = d->document->getValues(fieldName);
|
||||
|
||||
QStringList retValue;
|
||||
if (values) {
|
||||
for (qint32 i = 0; 0 != values[i]; ++i) {
|
||||
retValue.append(TCharToQString((const TCHAR*)values[i]));
|
||||
retValue.append(QHelp::TCharToQString((const TCHAR*)values[i]));
|
||||
delete [] values[i]; values[i] = 0;
|
||||
}
|
||||
delete values;
|
||||
|
|
|
@ -30,12 +30,10 @@
|
|||
//
|
||||
|
||||
#include "qfield_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QList>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/QStringList>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(document)
|
||||
|
@ -51,7 +49,7 @@ class QCLuceneIndexWriter;
|
|||
class QCLuceneIndexSearcher;
|
||||
class QCLuceneMultiSearcher;
|
||||
|
||||
class QHELP_EXPORT QCLuceneDocumentPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneDocumentPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneDocumentPrivate();
|
||||
|
@ -66,7 +64,7 @@ private:
|
|||
QCLuceneDocumentPrivate &operator=(const QCLuceneDocumentPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneDocument
|
||||
class Q_HELP_EXPORT QCLuceneDocument
|
||||
{
|
||||
public:
|
||||
QCLuceneDocument();
|
||||
|
|
|
@ -17,7 +17,6 @@
|
|||
|
||||
#include "qfield_p.h"
|
||||
#include "qreader_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/document/Field.h>
|
||||
|
@ -56,8 +55,8 @@ QCLuceneField::QCLuceneField(const QString &name, const QString &value, int conf
|
|||
: d(new QCLuceneFieldPrivate())
|
||||
, reader(0)
|
||||
{
|
||||
TCHAR* fieldName = QStringToTChar(name);
|
||||
TCHAR* fieldValue = QStringToTChar(value);
|
||||
TCHAR* fieldName = QHelp::QStringToTChar(name);
|
||||
TCHAR* fieldValue = QHelp::QStringToTChar(value);
|
||||
|
||||
d->field = new lucene::document::Field(fieldName, fieldValue, configs);
|
||||
|
||||
|
@ -70,7 +69,7 @@ QCLuceneField::QCLuceneField(const QString &name, QCLuceneReader *reader,
|
|||
: d(new QCLuceneFieldPrivate())
|
||||
, reader(reader)
|
||||
{
|
||||
TCHAR* fieldName = QStringToTChar(name);
|
||||
TCHAR* fieldName = QHelp::QStringToTChar(name);
|
||||
|
||||
reader->d->deleteCLuceneReader = false; // clucene takes ownership
|
||||
d->field = new lucene::document::Field(fieldName, reader->d->reader, configs);
|
||||
|
@ -85,12 +84,12 @@ QCLuceneField::~QCLuceneField()
|
|||
|
||||
QString QCLuceneField::name() const
|
||||
{
|
||||
return TCharToQString(d->field->name());
|
||||
return QHelp::TCharToQString(d->field->name());
|
||||
}
|
||||
|
||||
QString QCLuceneField::stringValue() const
|
||||
{
|
||||
return TCharToQString((const TCHAR*)d->field->stringValue());
|
||||
return QHelp::TCharToQString((const TCHAR*)d->field->stringValue());
|
||||
}
|
||||
|
||||
QCLuceneReader* QCLuceneField::readerValue() const
|
||||
|
@ -165,7 +164,7 @@ void QCLuceneField::setOmitNorms(bool omitNorms)
|
|||
|
||||
QString QCLuceneField::toString() const
|
||||
{
|
||||
return TCharToQString(d->field->toString());
|
||||
return QHelp::TCharToQString(d->field->toString());
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(document)
|
||||
|
@ -45,7 +44,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QCLuceneReader;
|
||||
class QCLuceneDocument;
|
||||
|
||||
class QHELP_EXPORT QCLuceneFieldPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneFieldPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneFieldPrivate();
|
||||
|
@ -60,7 +59,7 @@ private:
|
|||
QCLuceneFieldPrivate &operator=(const QCLuceneFieldPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneField
|
||||
class Q_HELP_EXPORT QCLuceneField
|
||||
{
|
||||
public:
|
||||
enum Store {
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QSharedData>
|
||||
#include <QtCore/qshareddata.h>
|
||||
|
||||
CL_NS_DEF(search)
|
||||
class Filter;
|
||||
|
@ -44,7 +43,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QCLuceneHits;
|
||||
class QCLuceneSearcher;
|
||||
|
||||
class QHELP_EXPORT QCLuceneFilterPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneFilterPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneFilterPrivate();
|
||||
|
@ -59,7 +58,7 @@ private:
|
|||
QCLuceneFilterPrivate &operator=(const QCLuceneFilterPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneFilter
|
||||
class Q_HELP_EXPORT QCLuceneFilter
|
||||
{
|
||||
QCLuceneFilter();
|
||||
virtual ~QCLuceneFilter();
|
||||
|
|
|
@ -33,9 +33,7 @@
|
|||
#include "qquery_p.h"
|
||||
#include "qfilter_p.h"
|
||||
#include "qdocument_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(search)
|
||||
|
@ -47,7 +45,7 @@ QT_BEGIN_NAMESPACE
|
|||
|
||||
class QCLuceneSearcher;
|
||||
|
||||
class QHELP_EXPORT QCLuceneHitsPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneHitsPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneHitsPrivate();
|
||||
|
@ -62,7 +60,7 @@ private:
|
|||
QCLuceneHitsPrivate &operator=(const QCLuceneHitsPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneHits
|
||||
class Q_HELP_EXPORT QCLuceneHits
|
||||
{
|
||||
public:
|
||||
QCLuceneHits(const QCLuceneSearcher &searcher, const QCLuceneQuery &query,
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qindexreader_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/index/IndexReader.h>
|
||||
|
@ -129,7 +128,7 @@ void QCLuceneIndexReader::deleteDocument(qint32 docNum)
|
|||
|
||||
bool QCLuceneIndexReader::hasNorms(const QString &field)
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(field);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(field);
|
||||
bool retValue = d->reader->hasNorms(fieldName);
|
||||
delete [] fieldName;
|
||||
|
||||
|
@ -154,14 +153,14 @@ bool QCLuceneIndexReader::document(qint32 index, QCLuceneDocument &document)
|
|||
|
||||
void QCLuceneIndexReader::setNorm(qint32 doc, const QString &field, qreal value)
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(field);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(field);
|
||||
d->reader->setNorm(int32_t(doc), fieldName, qreal(value));
|
||||
delete [] fieldName;
|
||||
}
|
||||
|
||||
void QCLuceneIndexReader::setNorm(qint32 doc, const QString &field, quint8 value)
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(field);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(field);
|
||||
d->reader->setNorm(int32_t(doc), fieldName, uint8_t(value));
|
||||
delete [] fieldName;
|
||||
}
|
||||
|
|
|
@ -31,11 +31,9 @@
|
|||
|
||||
#include "qterm_p.h"
|
||||
#include "qdocument_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QList>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(index)
|
||||
|
@ -48,7 +46,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QCLuceneIndexWriter;
|
||||
class QCLuceneIndexSearcher;
|
||||
|
||||
class QHELP_EXPORT QCLuceneIndexReaderPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneIndexReaderPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneIndexReaderPrivate();
|
||||
|
@ -63,7 +61,7 @@ private:
|
|||
QCLuceneIndexReaderPrivate &operator=(const QCLuceneIndexReaderPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneIndexReader
|
||||
class Q_HELP_EXPORT QCLuceneIndexReader
|
||||
{
|
||||
public:
|
||||
enum FieldOption {
|
||||
|
|
|
@ -31,10 +31,8 @@
|
|||
|
||||
#include "qanalyzer_p.h"
|
||||
#include "qdocument_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(index)
|
||||
|
@ -46,7 +44,7 @@ QT_BEGIN_NAMESPACE
|
|||
|
||||
class QCLuceneIndexReader;
|
||||
|
||||
class QHELP_EXPORT QCLuceneIndexWriterPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneIndexWriterPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneIndexWriterPrivate();
|
||||
|
@ -61,7 +59,7 @@ private:
|
|||
QCLuceneIndexWriterPrivate &operator=(const QCLuceneIndexWriterPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneIndexWriter
|
||||
class Q_HELP_EXPORT QCLuceneIndexWriter
|
||||
{
|
||||
public:
|
||||
enum {
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qquery_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/search/PhraseQuery.h>
|
||||
|
@ -68,21 +67,18 @@ qreal QCLuceneQuery::getBoost() const
|
|||
|
||||
QString QCLuceneQuery::getQueryName() const
|
||||
{
|
||||
return TCharToQString(d->query->getQueryName());
|
||||
return QHelp::TCharToQString(d->query->getQueryName());
|
||||
}
|
||||
|
||||
bool QCLuceneQuery::instanceOf(const QString &other) const
|
||||
{
|
||||
if (other == getQueryName())
|
||||
return true;
|
||||
|
||||
return false;
|
||||
return (other == getQueryName());
|
||||
}
|
||||
|
||||
QString QCLuceneQuery::toString(const QString &field) const
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(field);
|
||||
QString retValue = TCharToQString(d->query->toString(fieldName));
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(field);
|
||||
QString retValue = QHelp::TCharToQString(d->query->toString(fieldName));
|
||||
delete [] fieldName;
|
||||
|
||||
return retValue;
|
||||
|
@ -95,7 +91,7 @@ quint32 QCLuceneQuery::hashCode() const
|
|||
|
||||
QString QCLuceneQuery::toString() const
|
||||
{
|
||||
return TCharToQString(d->query->toString());
|
||||
return QHelp::TCharToQString(d->query->toString());
|
||||
}
|
||||
|
||||
bool QCLuceneQuery::equals(const QCLuceneQuery &other) const
|
||||
|
@ -118,7 +114,7 @@ QCLucenePrefixQuery::~QCLucenePrefixQuery()
|
|||
|
||||
QString QCLucenePrefixQuery::getClassName()
|
||||
{
|
||||
return TCharToQString(lucene::search::PrefixQuery::getClassName());
|
||||
return QHelp::TCharToQString(lucene::search::PrefixQuery::getClassName());
|
||||
}
|
||||
|
||||
QCLuceneTerm QCLucenePrefixQuery::getPrefix() const
|
||||
|
@ -145,7 +141,7 @@ QCLuceneRangeQuery::~QCLuceneRangeQuery()
|
|||
|
||||
QString QCLuceneRangeQuery::getClassName()
|
||||
{
|
||||
return TCharToQString(lucene::search::RangeQuery::getClassName());
|
||||
return QHelp::TCharToQString(lucene::search::RangeQuery::getClassName());
|
||||
}
|
||||
|
||||
QCLuceneTerm QCLuceneRangeQuery::getLowerTerm() const
|
||||
|
@ -177,7 +173,7 @@ QString QCLuceneRangeQuery::getField() const
|
|||
if (query == 0)
|
||||
return QString();
|
||||
|
||||
return TCharToQString(query->getField());
|
||||
return QHelp::TCharToQString(query->getField());
|
||||
}
|
||||
|
||||
|
||||
|
@ -195,7 +191,7 @@ QCLuceneTermQuery::~QCLuceneTermQuery()
|
|||
|
||||
QString QCLuceneTermQuery::getClassName()
|
||||
{
|
||||
return TCharToQString(lucene::search::TermQuery::getClassName());
|
||||
return QHelp::TCharToQString(lucene::search::TermQuery::getClassName());
|
||||
}
|
||||
|
||||
QCLuceneTerm QCLuceneTermQuery::getTerm() const
|
||||
|
@ -217,7 +213,7 @@ QCLuceneBooleanQuery::~QCLuceneBooleanQuery()
|
|||
|
||||
QString QCLuceneBooleanQuery::getClassName()
|
||||
{
|
||||
return TCharToQString(lucene::search::BooleanQuery::getClassName());
|
||||
return QHelp::TCharToQString(lucene::search::BooleanQuery::getClassName());
|
||||
}
|
||||
|
||||
quint32 QCLuceneBooleanQuery::getClauseCount() const
|
||||
|
@ -289,7 +285,7 @@ QCLucenePhraseQuery::~QCLucenePhraseQuery()
|
|||
|
||||
QString QCLucenePhraseQuery::getClassName()
|
||||
{
|
||||
return TCharToQString(lucene::search::RangeQuery::getClassName());
|
||||
return QHelp::TCharToQString(lucene::search::RangeQuery::getClassName());
|
||||
}
|
||||
|
||||
qint32 QCLucenePhraseQuery::getSlop() const
|
||||
|
@ -347,7 +343,7 @@ QString QCLucenePhraseQuery::getFieldName() const
|
|||
if (phraseQuery == 0)
|
||||
return QString();
|
||||
|
||||
return TCharToQString(phraseQuery->getFieldName());
|
||||
return QHelp::TCharToQString(phraseQuery->getFieldName());
|
||||
}
|
||||
|
||||
QList<QCLuceneTerm> QCLucenePhraseQuery::getTerms() const
|
||||
|
|
|
@ -30,11 +30,9 @@
|
|||
//
|
||||
|
||||
#include "qterm_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QList>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(search)
|
||||
|
@ -52,7 +50,7 @@ class QCLucenePrefixQuery;
|
|||
class QCLuceneBooleanQuery;
|
||||
class QCLucenePhraseQuery;
|
||||
|
||||
class QHELP_EXPORT QCLuceneQueryPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneQueryPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneQueryPrivate();
|
||||
|
@ -67,7 +65,7 @@ private:
|
|||
QCLuceneQueryPrivate &operator=(const QCLuceneQueryPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneQuery
|
||||
class Q_HELP_EXPORT QCLuceneQuery
|
||||
{
|
||||
public:
|
||||
virtual ~QCLuceneQuery();
|
||||
|
@ -95,7 +93,7 @@ private:
|
|||
QCLuceneQuery();
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLucenePrefixQuery : public QCLuceneQuery
|
||||
class Q_HELP_EXPORT QCLucenePrefixQuery : public QCLuceneQuery
|
||||
{
|
||||
public:
|
||||
QCLucenePrefixQuery(const QCLuceneTerm &prefix);
|
||||
|
@ -109,7 +107,7 @@ private:
|
|||
QCLuceneTerm prefix;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneRangeQuery : public QCLuceneQuery
|
||||
class Q_HELP_EXPORT QCLuceneRangeQuery : public QCLuceneQuery
|
||||
{
|
||||
public:
|
||||
QCLuceneRangeQuery(const QCLuceneTerm &lowerTerm,
|
||||
|
@ -129,7 +127,7 @@ private:
|
|||
QCLuceneTerm upperTerm;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneTermQuery : public QCLuceneQuery
|
||||
class Q_HELP_EXPORT QCLuceneTermQuery : public QCLuceneQuery
|
||||
{
|
||||
public:
|
||||
QCLuceneTermQuery(const QCLuceneTerm &term);
|
||||
|
@ -143,7 +141,7 @@ private:
|
|||
QCLuceneTerm term;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneBooleanQuery : public QCLuceneQuery
|
||||
class Q_HELP_EXPORT QCLuceneBooleanQuery : public QCLuceneQuery
|
||||
{
|
||||
public:
|
||||
QCLuceneBooleanQuery();
|
||||
|
@ -162,7 +160,7 @@ private:
|
|||
QList<QCLuceneQuery*> queries;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLucenePhraseQuery : public QCLuceneQuery
|
||||
class Q_HELP_EXPORT QCLucenePhraseQuery : public QCLuceneQuery
|
||||
{
|
||||
public:
|
||||
QCLucenePhraseQuery();
|
||||
|
|
|
@ -17,7 +17,6 @@
|
|||
|
||||
#include "qqueryparser_p.h"
|
||||
#include "qquery_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/queryParser/QueryParser.h>
|
||||
|
@ -51,7 +50,7 @@ QCLuceneQueryParser::QCLuceneQueryParser(const QString &field,
|
|||
, field(field)
|
||||
, analyzer(analyzer)
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(field);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(field);
|
||||
|
||||
d->queryParser = new lucene::queryParser::QueryParser(fieldName,
|
||||
analyzer.d->analyzer);
|
||||
|
@ -66,7 +65,7 @@ QCLuceneQueryParser::~QCLuceneQueryParser()
|
|||
|
||||
QCLuceneQuery* QCLuceneQueryParser::parse(const QString &query)
|
||||
{
|
||||
TCHAR *string = QStringToTChar(query);
|
||||
TCHAR *string = QHelp::QStringToTChar(query);
|
||||
|
||||
QCLuceneQuery *retValue = 0;
|
||||
lucene::search::Query* q = d->queryParser->parse(string);
|
||||
|
|
|
@ -31,11 +31,9 @@
|
|||
|
||||
#include "qreader_p.h"
|
||||
#include "qanalyzer_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/QStringList>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(queryParser)
|
||||
|
@ -48,7 +46,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QCLuceneQuery;
|
||||
class QCLuceneMultiFieldQueryParser;
|
||||
|
||||
class QHELP_EXPORT QCLuceneQueryParserPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneQueryParserPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneQueryParserPrivate();
|
||||
|
@ -63,7 +61,7 @@ private:
|
|||
QCLuceneQueryParserPrivate &operator=(const QCLuceneQueryParserPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneQueryParser
|
||||
class Q_HELP_EXPORT QCLuceneQueryParser
|
||||
{
|
||||
public:
|
||||
QCLuceneQueryParser(const QString &field, QCLuceneAnalyzer &analyzer);
|
||||
|
@ -85,7 +83,7 @@ private:
|
|||
QCLuceneAnalyzer analyzer;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneMultiFieldQueryParser : public QCLuceneQueryParser
|
||||
class Q_HELP_EXPORT QCLuceneMultiFieldQueryParser : public QCLuceneQueryParser
|
||||
{
|
||||
public:
|
||||
enum FieldFlags {
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qreader_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/util/Reader.h>
|
||||
|
@ -57,14 +56,14 @@ QCLuceneReader::~QCLuceneReader()
|
|||
|
||||
QCLuceneStringReader::QCLuceneStringReader(const QString &value)
|
||||
: QCLuceneReader()
|
||||
, string(QStringToTChar(value))
|
||||
, string(QHelp::QStringToTChar(value))
|
||||
{
|
||||
d->reader = new lucene::util::StringReader(string);
|
||||
}
|
||||
|
||||
QCLuceneStringReader::QCLuceneStringReader(const QString &value, qint32 length)
|
||||
: QCLuceneReader()
|
||||
, string(QStringToTChar(value))
|
||||
, string(QHelp::QStringToTChar(value))
|
||||
{
|
||||
d->reader = new lucene::util::StringReader(string, int32_t(length));
|
||||
}
|
||||
|
@ -72,7 +71,7 @@ QCLuceneStringReader::QCLuceneStringReader(const QString &value, qint32 length)
|
|||
QCLuceneStringReader::QCLuceneStringReader(const QString &value, qint32 length,
|
||||
bool copyData)
|
||||
: QCLuceneReader()
|
||||
, string(QStringToTChar(value))
|
||||
, string(QHelp::QStringToTChar(value))
|
||||
{
|
||||
d->reader = new lucene::util::StringReader(string, int32_t(length), copyData);
|
||||
}
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(util)
|
||||
|
@ -48,7 +47,7 @@ class QCLuceneDocument;
|
|||
class QCLuceneQueryParser;
|
||||
class QCLuceneStandardTokenizer;
|
||||
|
||||
class QHELP_EXPORT QCLuceneReaderPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneReaderPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneReaderPrivate();
|
||||
|
@ -63,7 +62,7 @@ private:
|
|||
QCLuceneReaderPrivate &operator=(const QCLuceneReaderPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneReader
|
||||
class Q_HELP_EXPORT QCLuceneReader
|
||||
{
|
||||
public:
|
||||
QCLuceneReader();
|
||||
|
@ -91,7 +90,7 @@ private:
|
|||
TCHAR *string;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneFileReader : public QCLuceneReader
|
||||
class Q_HELP_EXPORT QCLuceneFileReader : public QCLuceneReader
|
||||
{
|
||||
public:
|
||||
QCLuceneFileReader(const QString &path, const QString &encoding,
|
||||
|
|
|
@ -35,11 +35,9 @@
|
|||
#include "qfilter_p.h"
|
||||
#include "qdocument_p.h"
|
||||
#include "qindexreader_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QList>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(search)
|
||||
|
@ -54,7 +52,7 @@ class QCLuceneSearcher;
|
|||
class QCLuceneIndexSearcher;
|
||||
class QCLuceneMultiSearcher;
|
||||
|
||||
class QHELP_EXPORT QCLuceneSearchablePrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneSearchablePrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneSearchablePrivate();
|
||||
|
@ -69,7 +67,7 @@ private:
|
|||
QCLuceneSearchablePrivate &operator=(const QCLuceneSearchablePrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneSearchable
|
||||
class Q_HELP_EXPORT QCLuceneSearchable
|
||||
{
|
||||
public:
|
||||
virtual ~QCLuceneSearchable();
|
||||
|
@ -84,7 +82,7 @@ private:
|
|||
QCLuceneSearchable();
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneSearcher : public QCLuceneSearchable
|
||||
class Q_HELP_EXPORT QCLuceneSearcher : public QCLuceneSearchable
|
||||
{
|
||||
public:
|
||||
QCLuceneSearcher();
|
||||
|
@ -100,7 +98,7 @@ protected:
|
|||
friend class QCLuceneHits;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneIndexSearcher : public QCLuceneSearcher
|
||||
class Q_HELP_EXPORT QCLuceneIndexSearcher : public QCLuceneSearcher
|
||||
{
|
||||
public:
|
||||
QCLuceneIndexSearcher(const QString &path);
|
||||
|
@ -116,7 +114,7 @@ private:
|
|||
QCLuceneIndexReader reader;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneMultiSearcher : public QCLuceneSearcher
|
||||
class Q_HELP_EXPORT QCLuceneMultiSearcher : public QCLuceneSearcher
|
||||
{
|
||||
public:
|
||||
QCLuceneMultiSearcher(const QList<QCLuceneSearchable> searchables);
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qsort_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/search/Sort.h>
|
||||
|
@ -71,14 +70,14 @@ QCLuceneSort::~QCLuceneSort()
|
|||
|
||||
QString QCLuceneSort::toString() const
|
||||
{
|
||||
return TCharToQString(d->sort->toString());
|
||||
return QHelp::TCharToQString(d->sort->toString());
|
||||
}
|
||||
|
||||
void QCLuceneSort::setSort(const QStringList &fieldNames)
|
||||
{
|
||||
TCHAR **nameArray = new TCHAR*[fieldNames.count()];
|
||||
for (int i = 0; i < fieldNames.count(); ++i)
|
||||
nameArray[i] = QStringToTChar(fieldNames.at(i));
|
||||
nameArray[i] = QHelp::QStringToTChar(fieldNames.at(i));
|
||||
|
||||
d->sort->setSort((const TCHAR**)nameArray);
|
||||
|
||||
|
@ -89,7 +88,7 @@ void QCLuceneSort::setSort(const QStringList &fieldNames)
|
|||
|
||||
void QCLuceneSort::setSort(const QString &field, bool reverse)
|
||||
{
|
||||
TCHAR *name = QStringToTChar(field);
|
||||
TCHAR *name = QHelp::QStringToTChar(field);
|
||||
d->sort->setSort(name, reverse);
|
||||
delete [] name;
|
||||
}
|
||||
|
|
|
@ -33,7 +33,6 @@
|
|||
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/QStringList>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(search)
|
||||
|
@ -46,7 +45,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QCLuceneHits;
|
||||
class QCLuceneField;
|
||||
|
||||
class QHELP_EXPORT QCLuceneSortPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneSortPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneSortPrivate();
|
||||
|
@ -61,7 +60,7 @@ private:
|
|||
QCLuceneSortPrivate &operator=(const QCLuceneSortPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneSort
|
||||
class Q_HELP_EXPORT QCLuceneSort
|
||||
{
|
||||
public:
|
||||
QCLuceneSort();
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qterm_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/index/IndexReader.h>
|
||||
|
@ -53,8 +52,8 @@ QCLuceneTerm::QCLuceneTerm()
|
|||
QCLuceneTerm::QCLuceneTerm(const QString &field, const QString &text)
|
||||
: d(new QCLuceneTermPrivate())
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(field);
|
||||
TCHAR *termText = QStringToTChar(text);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(field);
|
||||
TCHAR *termText = QHelp::QStringToTChar(text);
|
||||
|
||||
d->term = new lucene::index::Term(fieldName, termText);
|
||||
|
||||
|
@ -65,7 +64,7 @@ QCLuceneTerm::QCLuceneTerm(const QString &field, const QString &text)
|
|||
QCLuceneTerm::QCLuceneTerm(const QCLuceneTerm &fieldTerm, const QString &text)
|
||||
: d(new QCLuceneTermPrivate())
|
||||
{
|
||||
TCHAR *termText = QStringToTChar(text);
|
||||
TCHAR *termText = QHelp::QStringToTChar(text);
|
||||
d->term = new lucene::index::Term(fieldTerm.d->term, termText);
|
||||
delete [] termText;
|
||||
}
|
||||
|
@ -77,12 +76,12 @@ QCLuceneTerm::~QCLuceneTerm()
|
|||
|
||||
QString QCLuceneTerm::field() const
|
||||
{
|
||||
return TCharToQString(d->term->field());
|
||||
return QHelp::TCharToQString(d->term->field());
|
||||
}
|
||||
|
||||
QString QCLuceneTerm::text() const
|
||||
{
|
||||
return TCharToQString(d->term->text());
|
||||
return QHelp::TCharToQString(d->term->text());
|
||||
}
|
||||
|
||||
void QCLuceneTerm::set(const QString &field, const QString &text)
|
||||
|
@ -97,8 +96,8 @@ void QCLuceneTerm::set(const QCLuceneTerm &fieldTerm, const QString &text)
|
|||
|
||||
void QCLuceneTerm::set(const QString &field, const QString &text, bool internField)
|
||||
{
|
||||
TCHAR *fieldName = QStringToTChar(field);
|
||||
TCHAR *termText = QStringToTChar(text);
|
||||
TCHAR *fieldName = QHelp::QStringToTChar(field);
|
||||
TCHAR *termText = QHelp::QStringToTChar(text);
|
||||
|
||||
d->term->set(fieldName, termText, internField);
|
||||
|
||||
|
@ -118,7 +117,7 @@ qint32 QCLuceneTerm::compareTo(const QCLuceneTerm &other) const
|
|||
|
||||
QString QCLuceneTerm::toString() const
|
||||
{
|
||||
return TCharToQString(d->term->toString());
|
||||
return QHelp::TCharToQString(d->term->toString());
|
||||
}
|
||||
|
||||
quint32 QCLuceneTerm::hashCode() const
|
||||
|
|
|
@ -33,7 +33,6 @@
|
|||
|
||||
#include <QtCore/QSharedData>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
|
||||
CL_NS_DEF(index)
|
||||
class Term;
|
||||
|
@ -48,7 +47,7 @@ class QCLucenePrefixQuery;
|
|||
class QCLuceneIndexReader;
|
||||
class QCLucenePhraseQuery;
|
||||
|
||||
class QHELP_EXPORT QCLuceneTermPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneTermPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneTermPrivate();
|
||||
|
@ -63,7 +62,7 @@ private:
|
|||
QCLuceneTermPrivate &operator=(const QCLuceneTermPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneTerm
|
||||
class Q_HELP_EXPORT QCLuceneTerm
|
||||
{
|
||||
public:
|
||||
QCLuceneTerm();
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qtoken_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/analysis/AnalysisHeader.h>
|
||||
|
@ -55,8 +54,8 @@ QCLuceneToken::QCLuceneToken()
|
|||
QCLuceneToken::QCLuceneToken(const QString &text, qint32 startOffset,
|
||||
qint32 endOffset, const QString &defaultTyp)
|
||||
: d(new QCLuceneTokenPrivate())
|
||||
, tokenText(QStringToTChar(text))
|
||||
, tokenType(QStringToTChar(defaultTyp))
|
||||
, tokenText(QHelp::QStringToTChar(text))
|
||||
, tokenType(QHelp::QStringToTChar(defaultTyp))
|
||||
{
|
||||
d->token = new lucene::analysis::Token(tokenText, int32_t(startOffset),
|
||||
int32_t(endOffset), tokenType);
|
||||
|
@ -90,13 +89,13 @@ void QCLuceneToken::setPositionIncrement(qint32 positionIncrement)
|
|||
|
||||
QString QCLuceneToken::termText() const
|
||||
{
|
||||
return TCharToQString(d->token->termText());
|
||||
return QHelp::TCharToQString(d->token->termText());
|
||||
}
|
||||
|
||||
void QCLuceneToken::setTermText(const QString &text)
|
||||
{
|
||||
delete [] tokenText;
|
||||
tokenText = QStringToTChar(text);
|
||||
tokenText = QHelp::QStringToTChar(text);
|
||||
d->token->setText(tokenText);
|
||||
}
|
||||
|
||||
|
@ -132,19 +131,19 @@ void QCLuceneToken::setEndOffset(qint32 value)
|
|||
|
||||
QString QCLuceneToken::type() const
|
||||
{
|
||||
return TCharToQString(d->token->type());
|
||||
return QHelp::TCharToQString(d->token->type());
|
||||
}
|
||||
|
||||
void QCLuceneToken::setType(const QString &type)
|
||||
{
|
||||
delete [] tokenType;
|
||||
tokenType = QStringToTChar(type);
|
||||
tokenType = QHelp::QStringToTChar(type);
|
||||
d->token->setType(tokenType);
|
||||
}
|
||||
|
||||
QString QCLuceneToken::toString() const
|
||||
{
|
||||
return TCharToQString(d->token->toString());
|
||||
return QHelp::TCharToQString(d->token->toString());
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(analysis)
|
||||
|
@ -46,7 +45,7 @@ class QCLuceneTokenizer;
|
|||
class QCLuceneTokenStream;
|
||||
class QCLuceneStandardTokenizer;
|
||||
|
||||
class QHELP_EXPORT QCLuceneTokenPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneTokenPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneTokenPrivate();
|
||||
|
@ -61,7 +60,7 @@ private:
|
|||
QCLuceneTokenPrivate &operator=(const QCLuceneTokenPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneToken
|
||||
class Q_HELP_EXPORT QCLuceneToken
|
||||
{
|
||||
public:
|
||||
QCLuceneToken();
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
****************************************************************************/
|
||||
|
||||
#include "qtokenizer_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <CLucene.h>
|
||||
#include <CLucene/analysis/AnalysisHeader.h>
|
||||
|
@ -73,7 +72,7 @@ bool QCLuceneStandardTokenizer::readApostrophe(const QString &string,
|
|||
if (stdTokenizer == 0)
|
||||
return false;
|
||||
|
||||
TCHAR* value = QStringToTChar(string);
|
||||
TCHAR* value = QHelp::QStringToTChar(string);
|
||||
lucene::util::StringBuffer buffer(value);
|
||||
bool retValue = stdTokenizer->ReadApostrophe(&buffer, token.d->token);
|
||||
delete [] value;
|
||||
|
@ -89,7 +88,7 @@ bool QCLuceneStandardTokenizer::readAt(const QString &string, QCLuceneToken &tok
|
|||
if (stdTokenizer == 0)
|
||||
return false;
|
||||
|
||||
TCHAR* value = QStringToTChar(string);
|
||||
TCHAR* value = QHelp::QStringToTChar(string);
|
||||
lucene::util::StringBuffer buffer(value);
|
||||
bool retValue = stdTokenizer->ReadAt(&buffer, token.d->token);
|
||||
delete [] value;
|
||||
|
@ -106,7 +105,7 @@ bool QCLuceneStandardTokenizer::readCompany(const QString &string,
|
|||
if (stdTokenizer == 0)
|
||||
return false;
|
||||
|
||||
TCHAR* value = QStringToTChar(string);
|
||||
TCHAR* value = QHelp::QStringToTChar(string);
|
||||
lucene::util::StringBuffer buffer(value);
|
||||
bool retValue = stdTokenizer->ReadCompany(&buffer, token.d->token);
|
||||
delete [] value;
|
||||
|
|
|
@ -32,14 +32,13 @@
|
|||
#include "qtoken_p.h"
|
||||
#include "qreader_p.h"
|
||||
#include "qtokenstream_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QChar>
|
||||
#include <QtCore/QString>
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QHELP_EXPORT QCLuceneTokenizer : public QCLuceneTokenStream
|
||||
class Q_HELP_EXPORT QCLuceneTokenizer : public QCLuceneTokenStream
|
||||
{
|
||||
public:
|
||||
QCLuceneTokenizer(const QCLuceneReader &reader);
|
||||
|
@ -56,7 +55,7 @@ private:
|
|||
QCLuceneReader reader;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneStandardTokenizer : public QCLuceneTokenizer
|
||||
class Q_HELP_EXPORT QCLuceneStandardTokenizer : public QCLuceneTokenizer
|
||||
{
|
||||
public:
|
||||
QCLuceneStandardTokenizer(const QCLuceneReader &reader);
|
||||
|
|
|
@ -30,10 +30,8 @@
|
|||
//
|
||||
|
||||
#include "qtoken_p.h"
|
||||
#include "qclucene_global_p.h"
|
||||
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/qshareddata.h>
|
||||
#include <QtCore/QSharedData>
|
||||
|
||||
CL_NS_DEF(analysis)
|
||||
|
@ -52,7 +50,7 @@ class QCLuceneStandardAnalyzer;
|
|||
class QCLuceneWhitespaceAnalyzer;
|
||||
class QCLucenePerFieldAnalyzerWrapper;
|
||||
|
||||
class QHELP_EXPORT QCLuceneTokenStreamPrivate : public QSharedData
|
||||
class Q_HELP_EXPORT QCLuceneTokenStreamPrivate : public QSharedData
|
||||
{
|
||||
public:
|
||||
QCLuceneTokenStreamPrivate();
|
||||
|
@ -67,7 +65,7 @@ private:
|
|||
QCLuceneTokenStreamPrivate &operator=(const QCLuceneTokenStreamPrivate &other);
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QCLuceneTokenStream
|
||||
class Q_HELP_EXPORT QCLuceneTokenStream
|
||||
{
|
||||
public:
|
||||
virtual ~QCLuceneTokenStream();
|
||||
|
|
|
@ -42,7 +42,7 @@
|
|||
#include <QtCore/QCoreApplication>
|
||||
#include <QtCore/QHash>
|
||||
#include <QtCore/QRegExp>
|
||||
#include <QtCore/qmutex.h>
|
||||
#include <QtCore/QMutex>
|
||||
#include <QtGui/QTextDocument>
|
||||
|
||||
#include "qhelp_global.h"
|
||||
|
|
|
@ -42,23 +42,12 @@
|
|||
#ifndef QHELP_GLOBAL_H
|
||||
#define QHELP_GLOBAL_H
|
||||
|
||||
#include <QtCore/qglobal.h>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/QObject>
|
||||
|
||||
QT_BEGIN_HEADER
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
|
||||
#if !defined(QT_SHARED) && !defined(QT_DLL)
|
||||
# define QHELP_EXPORT
|
||||
#elif defined(QHELP_LIB)
|
||||
# define QHELP_EXPORT Q_DECL_EXPORT
|
||||
#else
|
||||
# define QHELP_EXPORT Q_DECL_IMPORT
|
||||
#endif
|
||||
|
||||
class QHelpGlobal {
|
||||
public:
|
||||
static QString uniquifyConnectionName(const QString &name, void *pointer);
|
||||
|
|
|
@ -60,7 +60,7 @@ class QHelpContentModelPrivate;
|
|||
class QHelpEngine;
|
||||
class QHelpContentProvider;
|
||||
|
||||
class QHELP_EXPORT QHelpContentItem
|
||||
class Q_HELP_EXPORT QHelpContentItem
|
||||
{
|
||||
public:
|
||||
~QHelpContentItem();
|
||||
|
@ -82,7 +82,7 @@ private:
|
|||
friend class QHelpContentProvider;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QHelpContentModel : public QAbstractItemModel
|
||||
class Q_HELP_EXPORT QHelpContentModel : public QAbstractItemModel
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
@ -114,7 +114,7 @@ private:
|
|||
friend class QHelpEnginePrivate;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QHelpContentWidget : public QTreeView
|
||||
class Q_HELP_EXPORT QHelpContentWidget : public QTreeView
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -62,7 +62,7 @@ QT_BEGIN_HEADER
|
|||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QHELP_EXPORT QHelpDataContentItem
|
||||
class Q_HELP_EXPORT QHelpDataContentItem
|
||||
{
|
||||
public:
|
||||
QHelpDataContentItem(QHelpDataContentItem *parent, const QString &title,
|
||||
|
@ -79,7 +79,7 @@ private:
|
|||
QList<QHelpDataContentItem*> m_children;
|
||||
};
|
||||
|
||||
struct QHELP_EXPORT QHelpDataIndexItem {
|
||||
struct Q_HELP_EXPORT QHelpDataIndexItem {
|
||||
QHelpDataIndexItem() {}
|
||||
QHelpDataIndexItem(const QString &n, const QString &id, const QString &r)
|
||||
: name(n), identifier(id), reference(r) {}
|
||||
|
@ -105,7 +105,7 @@ public:
|
|||
QStringList files;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QHelpDataFilterSection
|
||||
class Q_HELP_EXPORT QHelpDataFilterSection
|
||||
{
|
||||
public:
|
||||
QHelpDataFilterSection();
|
||||
|
@ -129,12 +129,12 @@ private:
|
|||
QSharedDataPointer<QHelpDataFilterSectionData> d;
|
||||
};
|
||||
|
||||
struct QHELP_EXPORT QHelpDataCustomFilter {
|
||||
struct Q_HELP_EXPORT QHelpDataCustomFilter {
|
||||
QStringList filterAttributes;
|
||||
QString name;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QHelpDataInterface
|
||||
class Q_HELP_EXPORT QHelpDataInterface
|
||||
{
|
||||
public:
|
||||
QHelpDataInterface() {}
|
||||
|
|
|
@ -56,7 +56,7 @@ class QHelpIndexWidget;
|
|||
class QHelpEnginePrivate;
|
||||
class QHelpSearchEngine;
|
||||
|
||||
class QHELP_EXPORT QHelpEngine : public QHelpEngineCore
|
||||
class Q_HELP_EXPORT QHelpEngine : public QHelpEngineCore
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ QT_BEGIN_NAMESPACE
|
|||
|
||||
class QHelpEngineCorePrivate;
|
||||
|
||||
class QHELP_EXPORT QHelpEngineCore : public QObject
|
||||
class Q_HELP_EXPORT QHelpEngineCore : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(bool autoSaveFilter READ autoSaveFilter WRITE setAutoSaveFilter)
|
||||
|
|
|
@ -64,7 +64,7 @@ QT_BEGIN_NAMESPACE
|
|||
|
||||
class QHelpGeneratorPrivate;
|
||||
|
||||
class QHELP_EXPORT QHelpGenerator : public QObject
|
||||
class Q_HELP_EXPORT QHelpGenerator : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QHelpEnginePrivate;
|
||||
class QHelpIndexModelPrivate;
|
||||
|
||||
class QHELP_EXPORT QHelpIndexModel : public QStringListModel
|
||||
class Q_HELP_EXPORT QHelpIndexModel : public QStringListModel
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
@ -84,7 +84,7 @@ private:
|
|||
friend class QHelpEnginePrivate;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QHelpIndexWidget : public QListView
|
||||
class Q_HELP_EXPORT QHelpIndexWidget : public QListView
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -62,7 +62,7 @@ QT_BEGIN_NAMESPACE
|
|||
|
||||
class QHelpProjectDataPrivate;
|
||||
|
||||
class QHELP_EXPORT QHelpProjectData : public QHelpDataInterface
|
||||
class Q_HELP_EXPORT QHelpProjectData : public QHelpDataInterface
|
||||
{
|
||||
public:
|
||||
QHelpProjectData();
|
||||
|
|
|
@ -60,7 +60,7 @@ class QHelpSearchQueryWidget;
|
|||
class QHelpSearchResultWidget;
|
||||
class QHelpSearchEnginePrivate;
|
||||
|
||||
class QHELP_EXPORT QHelpSearchQuery
|
||||
class Q_HELP_EXPORT QHelpSearchQuery
|
||||
{
|
||||
public:
|
||||
enum FieldName { DEFAULT = 0, FUZZY, WITHOUT, PHRASE, ALL, ATLEAST };
|
||||
|
@ -74,7 +74,7 @@ public:
|
|||
QStringList wordList;
|
||||
};
|
||||
|
||||
class QHELP_EXPORT QHelpSearchEngine : public QObject
|
||||
class Q_HELP_EXPORT QHelpSearchEngine : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -59,7 +59,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QFocusEvent;
|
||||
class QHelpSearchQueryWidgetPrivate;
|
||||
|
||||
class QHELP_EXPORT QHelpSearchQueryWidget : public QWidget
|
||||
class Q_HELP_EXPORT QHelpSearchQueryWidget : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@ QT_BEGIN_NAMESPACE
|
|||
|
||||
class QHelpSearchResultWidgetPrivate;
|
||||
|
||||
class QHELP_EXPORT QHelpSearchResultWidget : public QWidget
|
||||
class Q_HELP_EXPORT QHelpSearchResultWidget : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
add_definitions(
|
||||
-DQT_BUILD_TEST_LIB
|
||||
-DQT_NO_CAST_TO_ASCII
|
||||
-DQT_NO_CAST_FROM_ASCII
|
||||
-DQTESTLIB_MAKEDLL
|
||||
-DQT_NO_DATASTREAM
|
||||
)
|
||||
set(EXTRA_TEST_LIBS KtCore)
|
||||
|
|
|
@ -61,7 +61,7 @@ namespace QTest
|
|||
// QTestlib API. It exists purely as an implementation detail.
|
||||
//
|
||||
//
|
||||
class Q_TESTLIB_EXPORT QBenchmarkIterationController
|
||||
class Q_TEST_EXPORT QBenchmarkIterationController
|
||||
{
|
||||
public:
|
||||
enum RunMode { RepeatUntilValidMeasurement, RunOnce };
|
||||
|
@ -87,7 +87,7 @@ public:
|
|||
|
||||
namespace QTest
|
||||
{
|
||||
void Q_TESTLIB_EXPORT setBenchmarkResult(qreal result, QBenchmarkMetric metric);
|
||||
void Q_TEST_EXPORT setBenchmarkResult(qreal result, QBenchmarkMetric metric);
|
||||
}
|
||||
|
||||
// --- END public API ---
|
||||
|
|
|
@ -130,7 +130,7 @@ public:
|
|||
QBenchmarkGlobalData:current is created at the beginning of qExec()
|
||||
and cleared at the end.
|
||||
*/
|
||||
class Q_TESTLIB_EXPORT QBenchmarkGlobalData
|
||||
class Q_TEST_EXPORT QBenchmarkGlobalData
|
||||
{
|
||||
public:
|
||||
static QBenchmarkGlobalData *current;
|
||||
|
@ -161,7 +161,7 @@ private:
|
|||
created at the beginning of qInvokeTestMethod() and cleared at
|
||||
the end.
|
||||
*/
|
||||
class Q_TESTLIB_EXPORT QBenchmarkTestMethodData
|
||||
class Q_TEST_EXPORT QBenchmarkTestMethodData
|
||||
{
|
||||
public:
|
||||
static QBenchmarkTestMethodData *current;
|
||||
|
@ -191,8 +191,8 @@ namespace QTest
|
|||
void setIterationCountHint(int count);
|
||||
void setIterationCount(int count);
|
||||
|
||||
Q_TESTLIB_EXPORT void beginBenchmarkMeasurement();
|
||||
Q_TESTLIB_EXPORT quint64 endBenchmarkMeasurement();
|
||||
Q_TEST_EXPORT void beginBenchmarkMeasurement();
|
||||
Q_TEST_EXPORT quint64 endBenchmarkMeasurement();
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
|
|
@ -395,12 +395,12 @@ void QPlainTestLogger::startLogging()
|
|||
if (hasRandomSeed) {
|
||||
QTest::qt_snprintf(buf, sizeof(buf),
|
||||
"********* Start testing of %s *********\n"
|
||||
"Config: Using QTest library " QTEST_VERSION_STR
|
||||
"Config: Using QTest library " QT_VERSION_STR
|
||||
", Qt %s, Random seed %d\n", QTestResult::currentTestObjectName(), qVersion(), randomSeed);
|
||||
} else {
|
||||
QTest::qt_snprintf(buf, sizeof(buf),
|
||||
"********* Start testing of %s *********\n"
|
||||
"Config: Using QTest library " QTEST_VERSION_STR
|
||||
"Config: Using QTest library " QT_VERSION_STR
|
||||
", Qt %s\n", QTestResult::currentTestObjectName(), qVersion());
|
||||
}
|
||||
}
|
||||
|
|
|
@ -48,40 +48,25 @@ QT_BEGIN_HEADER
|
|||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
|
||||
#ifdef QTEST_EMBED
|
||||
# define Q_TESTLIB_EXPORT
|
||||
#elif !defined(QT_SHARED)
|
||||
# define Q_TESTLIB_EXPORT
|
||||
#else
|
||||
# ifdef QTESTLIB_MAKEDLL
|
||||
# define Q_TESTLIB_EXPORT Q_DECL_EXPORT
|
||||
# else
|
||||
# define Q_TESTLIB_EXPORT Q_DECL_IMPORT
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if defined (Q_CC_SUN) || defined (Q_CC_XLC) || (defined (Q_CC_GNU) && (__GNUC__ - 0 < 3)) || defined (Q_CC_NOKIAX86)
|
||||
# define QTEST_NO_SPECIALIZATIONS
|
||||
#endif
|
||||
|
||||
|
||||
#if (defined Q_CC_HPACC) && (defined __ia64)
|
||||
# ifdef Q_TESTLIB_EXPORT
|
||||
# undef Q_TESTLIB_EXPORT
|
||||
# ifdef Q_TEST_EXPORT
|
||||
# undef Q_TEST_EXPORT
|
||||
# endif
|
||||
# define Q_TESTLIB_EXPORT
|
||||
# define Q_TEST_EXPORT
|
||||
#endif
|
||||
|
||||
#define QTEST_VERSION QT_VERSION
|
||||
#define QTEST_VERSION_STR QT_VERSION_STR
|
||||
|
||||
namespace QTest
|
||||
{
|
||||
enum SkipMode { SkipSingle = 1, SkipAll = 2 };
|
||||
enum TestFailMode { Abort = 1, Continue = 2 };
|
||||
|
||||
int Q_TESTLIB_EXPORT qt_snprintf(char *str, int size, const char *format, ...);
|
||||
int Q_TEST_EXPORT qt_snprintf(char *str, int size, const char *format, ...);
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
|
|
@ -917,7 +917,7 @@ static void invokeMethod(QObject *obj, const char *methodName)
|
|||
}
|
||||
}
|
||||
|
||||
bool Q_TESTLIB_EXPORT defaultKeyVerbose()
|
||||
bool Q_TEST_EXPORT defaultKeyVerbose()
|
||||
{
|
||||
if (keyVerbose == -1) {
|
||||
keyVerbose = qgetenv("QTEST_KEYEVENT_VERBOSE").constData() ? 1 : 0;
|
||||
|
@ -936,7 +936,7 @@ int defaultEventDelay()
|
|||
return eventDelay;
|
||||
}
|
||||
|
||||
int Q_TESTLIB_EXPORT defaultMouseDelay()
|
||||
int Q_TEST_EXPORT defaultMouseDelay()
|
||||
{
|
||||
if (mouseDelay == -1) {
|
||||
if (qgetenv("QTEST_MOUSEEVENT_DELAY").constData())
|
||||
|
@ -947,7 +947,7 @@ int Q_TESTLIB_EXPORT defaultMouseDelay()
|
|||
return mouseDelay;
|
||||
}
|
||||
|
||||
int Q_TESTLIB_EXPORT defaultKeyDelay()
|
||||
int Q_TEST_EXPORT defaultKeyDelay()
|
||||
{
|
||||
if (keyDelay == -1) {
|
||||
if (qgetenv("QTEST_KEYEVENT_DELAY").constData())
|
||||
|
@ -1014,10 +1014,10 @@ static bool isValidSlot(const QMetaMethod &sl)
|
|||
return true;
|
||||
}
|
||||
|
||||
Q_TESTLIB_EXPORT bool printAvailableFunctions = false;
|
||||
Q_TESTLIB_EXPORT bool printAvailableTags = false;
|
||||
Q_TESTLIB_EXPORT QStringList testFunctions;
|
||||
Q_TESTLIB_EXPORT QStringList testTags;
|
||||
Q_TEST_EXPORT bool printAvailableFunctions = false;
|
||||
Q_TEST_EXPORT bool printAvailableTags = false;
|
||||
Q_TEST_EXPORT QStringList testFunctions;
|
||||
Q_TEST_EXPORT QStringList testTags;
|
||||
|
||||
static void qPrintTestSlots()
|
||||
{
|
||||
|
@ -1098,7 +1098,7 @@ static int qToInt(char *str)
|
|||
return l;
|
||||
}
|
||||
|
||||
Q_TESTLIB_EXPORT void qtest_qParseArgs(int argc, char *argv[], bool qml)
|
||||
Q_TEST_EXPORT void qtest_qParseArgs(int argc, char *argv[], bool qml)
|
||||
{
|
||||
const char *testOptions =
|
||||
" options:\n"
|
||||
|
@ -2223,7 +2223,7 @@ bool QTest::compare_helper(bool success, const char *msg, char *val1, char *val2
|
|||
\internal
|
||||
*/
|
||||
template <>
|
||||
Q_TESTLIB_EXPORT bool QTest::qCompare<float>(float const &t1, float const &t2, const char *actual, const char *expected,
|
||||
Q_TEST_EXPORT bool QTest::qCompare<float>(float const &t1, float const &t2, const char *actual, const char *expected,
|
||||
const char *file, int line)
|
||||
{
|
||||
return qFuzzyCompare(t1, t2)
|
||||
|
@ -2236,7 +2236,7 @@ Q_TESTLIB_EXPORT bool QTest::qCompare<float>(float const &t1, float const &t2, c
|
|||
\internal
|
||||
*/
|
||||
template <>
|
||||
Q_TESTLIB_EXPORT bool QTest::qCompare<double>(double const &t1, double const &t2, const char *actual, const char *expected,
|
||||
Q_TEST_EXPORT bool QTest::qCompare<double>(double const &t1, double const &t2, const char *actual, const char *expected,
|
||||
const char *file, int line)
|
||||
{
|
||||
return qFuzzyCompare(t1, t2)
|
||||
|
@ -2246,7 +2246,7 @@ Q_TESTLIB_EXPORT bool QTest::qCompare<double>(double const &t1, double const &t2
|
|||
}
|
||||
|
||||
#define COMPARE_IMPL2(TYPE, FORMAT) \
|
||||
template <> Q_TESTLIB_EXPORT char *QTest::toString<TYPE >(const TYPE &t) \
|
||||
template <> Q_TEST_EXPORT char *QTest::toString<TYPE >(const TYPE &t) \
|
||||
{ \
|
||||
char *msg = new char[128]; \
|
||||
qt_snprintf(msg, 128, #FORMAT, t); \
|
||||
|
|
|
@ -114,7 +114,7 @@ class QObject;
|
|||
class QTestData;
|
||||
|
||||
#define QTEST_COMPARE_DECL(KLASS)\
|
||||
template<> Q_TESTLIB_EXPORT char *toString<KLASS >(const KLASS &);
|
||||
template<> Q_TEST_EXPORT char *toString<KLASS >(const KLASS &);
|
||||
|
||||
namespace QTest
|
||||
{
|
||||
|
@ -125,50 +125,50 @@ namespace QTest
|
|||
}
|
||||
|
||||
|
||||
Q_TESTLIB_EXPORT char *toHexRepresentation(const char *ba, int length);
|
||||
Q_TESTLIB_EXPORT char *toString(const char *);
|
||||
Q_TESTLIB_EXPORT char *toString(const void *);
|
||||
Q_TEST_EXPORT char *toHexRepresentation(const char *ba, int length);
|
||||
Q_TEST_EXPORT char *toString(const char *);
|
||||
Q_TEST_EXPORT char *toString(const void *);
|
||||
|
||||
Q_TESTLIB_EXPORT int qExec(QObject *testObject, int argc = 0, char **argv = 0);
|
||||
Q_TESTLIB_EXPORT int qExec(QObject *testObject, const QStringList &arguments);
|
||||
Q_TEST_EXPORT int qExec(QObject *testObject, int argc = 0, char **argv = 0);
|
||||
Q_TEST_EXPORT int qExec(QObject *testObject, const QStringList &arguments);
|
||||
|
||||
Q_TESTLIB_EXPORT bool qVerify(bool statement, const char *statementStr, const char *description,
|
||||
Q_TEST_EXPORT bool qVerify(bool statement, const char *statementStr, const char *description,
|
||||
const char *file, int line);
|
||||
Q_TESTLIB_EXPORT void qFail(const char *statementStr, const char *file, int line);
|
||||
Q_TESTLIB_EXPORT void qSkip(const char *message, SkipMode mode, const char *file, int line);
|
||||
Q_TESTLIB_EXPORT bool qExpectFail(const char *dataIndex, const char *comment, TestFailMode mode,
|
||||
Q_TEST_EXPORT void qFail(const char *statementStr, const char *file, int line);
|
||||
Q_TEST_EXPORT void qSkip(const char *message, SkipMode mode, const char *file, int line);
|
||||
Q_TEST_EXPORT bool qExpectFail(const char *dataIndex, const char *comment, TestFailMode mode,
|
||||
const char *file, int line);
|
||||
Q_TESTLIB_EXPORT void qWarn(const char *message);
|
||||
Q_TESTLIB_EXPORT void ignoreMessage(QtMsgType type, const char *message);
|
||||
Q_TEST_EXPORT void qWarn(const char *message);
|
||||
Q_TEST_EXPORT void ignoreMessage(QtMsgType type, const char *message);
|
||||
|
||||
Q_TESTLIB_EXPORT void *qData(const char *tagName, int typeId);
|
||||
Q_TESTLIB_EXPORT void *qGlobalData(const char *tagName, int typeId);
|
||||
Q_TESTLIB_EXPORT void *qElementData(const char *elementName, int metaTypeId);
|
||||
Q_TESTLIB_EXPORT QObject *testObject();
|
||||
Q_TEST_EXPORT void *qData(const char *tagName, int typeId);
|
||||
Q_TEST_EXPORT void *qGlobalData(const char *tagName, int typeId);
|
||||
Q_TEST_EXPORT void *qElementData(const char *elementName, int metaTypeId);
|
||||
Q_TEST_EXPORT QObject *testObject();
|
||||
|
||||
Q_TESTLIB_EXPORT const char *currentAppName();
|
||||
Q_TEST_EXPORT const char *currentAppName();
|
||||
|
||||
Q_TESTLIB_EXPORT const char *currentTestFunction();
|
||||
Q_TESTLIB_EXPORT const char *currentDataTag();
|
||||
Q_TESTLIB_EXPORT bool currentTestFailed();
|
||||
Q_TEST_EXPORT const char *currentTestFunction();
|
||||
Q_TEST_EXPORT const char *currentDataTag();
|
||||
Q_TEST_EXPORT bool currentTestFailed();
|
||||
|
||||
Q_TESTLIB_EXPORT Qt::Key asciiToKey(char ascii);
|
||||
Q_TESTLIB_EXPORT char keyToAscii(Qt::Key key);
|
||||
Q_TEST_EXPORT Qt::Key asciiToKey(char ascii);
|
||||
Q_TEST_EXPORT char keyToAscii(Qt::Key key);
|
||||
|
||||
Q_TESTLIB_EXPORT bool compare_helper(bool success, const char *msg, const char *file,
|
||||
Q_TEST_EXPORT bool compare_helper(bool success, const char *msg, const char *file,
|
||||
int line);
|
||||
Q_TESTLIB_EXPORT bool compare_helper(bool success, const char *msg, char *val1, char *val2,
|
||||
Q_TEST_EXPORT bool compare_helper(bool success, const char *msg, char *val1, char *val2,
|
||||
const char *expected, const char *actual,
|
||||
const char *file, int line);
|
||||
Q_TESTLIB_EXPORT void qSleep(int ms);
|
||||
Q_TESTLIB_EXPORT void addColumnInternal(int id, const char *name);
|
||||
Q_TEST_EXPORT void qSleep(int ms);
|
||||
Q_TEST_EXPORT void addColumnInternal(int id, const char *name);
|
||||
|
||||
template <typename T>
|
||||
inline void addColumn(const char *name, T * = 0)
|
||||
{
|
||||
addColumnInternal(qMetaTypeId<T>(), name);
|
||||
}
|
||||
Q_TESTLIB_EXPORT QTestData &newRow(const char *dataTag);
|
||||
Q_TEST_EXPORT QTestData &newRow(const char *dataTag);
|
||||
|
||||
template <typename T>
|
||||
inline bool qCompare(T const &t1, T const &t2, const char *actual, const char *expected,
|
||||
|
@ -182,11 +182,11 @@ namespace QTest
|
|||
|
||||
|
||||
template <>
|
||||
Q_TESTLIB_EXPORT bool qCompare<float>(float const &t1, float const &t2,
|
||||
Q_TEST_EXPORT bool qCompare<float>(float const &t1, float const &t2,
|
||||
const char *actual, const char *expected, const char *file, int line);
|
||||
|
||||
template <>
|
||||
Q_TESTLIB_EXPORT bool qCompare<double>(double const &t1, double const &t2,
|
||||
Q_TEST_EXPORT bool qCompare<double>(double const &t1, double const &t2,
|
||||
const char *actual, const char *expected, const char *file, int line);
|
||||
|
||||
inline bool compare_ptr_helper(const void *t1, const void *t2, const char *actual,
|
||||
|
@ -198,7 +198,7 @@ namespace QTest
|
|||
toString(t1), toString(t2), actual, expected, file, line);
|
||||
}
|
||||
|
||||
Q_TESTLIB_EXPORT bool compare_string_helper(const char *t1, const char *t2, const char *actual,
|
||||
Q_TEST_EXPORT bool compare_string_helper(const char *t1, const char *t2, const char *actual,
|
||||
const char *expected, const char *file, int line);
|
||||
|
||||
QTEST_COMPARE_DECL(short)
|
||||
|
|
|
@ -55,7 +55,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QTestTable;
|
||||
class QTestDataPrivate;
|
||||
|
||||
class Q_TESTLIB_EXPORT QTestData
|
||||
class Q_TEST_EXPORT QTestData
|
||||
{
|
||||
public:
|
||||
~QTestData();
|
||||
|
|
|
@ -54,7 +54,7 @@ QT_BEGIN_HEADER
|
|||
QT_BEGIN_NAMESPACE
|
||||
|
||||
|
||||
class Q_TESTLIB_EXPORT QTestEventLoop : public QObject
|
||||
class Q_TEST_EXPORT QTestEventLoop : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ namespace QTest
|
|||
Qt::KeyboardModifiers modifier, QString text, bool repeat, int delay=-1)
|
||||
{
|
||||
QTEST_ASSERT(widget);
|
||||
extern int Q_TESTLIB_EXPORT defaultKeyDelay();
|
||||
extern int Q_TEST_EXPORT defaultKeyDelay();
|
||||
|
||||
if (delay == -1 || delay < defaultKeyDelay())
|
||||
delay = defaultKeyDelay();
|
||||
|
|
|
@ -167,10 +167,10 @@ void QTestLightXmlStreamer::output(QTestElement *element) const
|
|||
QTestCharBuffer buf;
|
||||
if (logger()->hasRandomSeed()) {
|
||||
QTest::qt_asprintf(&buf, "<Environment>\n <QtVersion>%s</QtVersion>\n <QTestVersion>%s</QTestVersion>\n <RandomSeed>%d</RandomSeed>\n",
|
||||
qVersion(), QTEST_VERSION_STR, logger()->randomSeed() );
|
||||
qVersion(), QT_VERSION_STR, logger()->randomSeed() );
|
||||
} else {
|
||||
QTest::qt_asprintf(&buf, "<Environment>\n <QtVersion>%s</QtVersion>\n <QTestVersion>%s</QTestVersion>\n",
|
||||
qVersion(), QTEST_VERSION_STR );
|
||||
qVersion(), QT_VERSION_STR );
|
||||
}
|
||||
outputString(buf.constData());
|
||||
|
||||
|
|
|
@ -191,7 +191,7 @@ void initLogger()
|
|||
}
|
||||
}
|
||||
|
||||
extern Q_TESTLIB_EXPORT bool printAvailableTags;
|
||||
extern Q_TEST_EXPORT bool printAvailableTags;
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -59,7 +59,7 @@ QT_BEGIN_NAMESPACE
|
|||
|
||||
class QBenchmarkResult;
|
||||
|
||||
class Q_TESTLIB_EXPORT QTestLog
|
||||
class Q_TEST_EXPORT QTestLog
|
||||
{
|
||||
public:
|
||||
enum LogMode { Plain = 0, XML, LightXML, XunitXML };
|
||||
|
|
|
@ -126,7 +126,7 @@ void QTestLogger::stopLogging()
|
|||
|
||||
property = new QTestElement(QTest::LET_Property);
|
||||
property->addAttribute(QTest::AI_Name, "QTestVersion");
|
||||
property->addAttribute(QTest::AI_PropertyValue, QTEST_VERSION_STR);
|
||||
property->addAttribute(QTest::AI_PropertyValue, QT_VERSION_STR);
|
||||
properties->addLogElement(property);
|
||||
|
||||
property = new QTestElement(QTest::LET_Property);
|
||||
|
|
|
@ -66,7 +66,7 @@ namespace QTest
|
|||
Qt::KeyboardModifiers stateKey, QPoint pos, int delay=-1)
|
||||
{
|
||||
QTEST_ASSERT(widget);
|
||||
extern int Q_TESTLIB_EXPORT defaultMouseDelay();
|
||||
extern int Q_TEST_EXPORT defaultMouseDelay();
|
||||
|
||||
if (delay == -1 || delay < defaultMouseDelay())
|
||||
delay = defaultMouseDelay();
|
||||
|
|
|
@ -60,7 +60,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QTestResultPrivate;
|
||||
class QTestData;
|
||||
|
||||
class Q_TESTLIB_EXPORT QTestResult
|
||||
class Q_TEST_EXPORT QTestResult
|
||||
{
|
||||
public:
|
||||
enum TestLocation { NoWhere = 0, DataFunc = 1, InitFunc = 2, Func = 3, CleanupFunc = 4 };
|
||||
|
|
|
@ -60,7 +60,7 @@ QT_BEGIN_NAMESPACE
|
|||
class QTestData;
|
||||
class QTestTablePrivate;
|
||||
|
||||
class Q_TESTLIB_EXPORT QTestTable
|
||||
class Q_TEST_EXPORT QTestTable
|
||||
{
|
||||
public:
|
||||
QTestTable();
|
||||
|
|
|
@ -207,10 +207,10 @@ void QTestXmlStreamer::output(QTestElement *element) const
|
|||
|
||||
if (logger()->hasRandomSeed()) {
|
||||
QTest::qt_asprintf(&buf, "<Environment>\n <QtVersion>%s</QtVersion>\n <QTestVersion>%s</QTestVersion>\n <RandomSeed>%d</RandomSeed>\n",
|
||||
qVersion(), QTEST_VERSION_STR, logger()->randomSeed() );
|
||||
qVersion(), QT_VERSION_STR, logger()->randomSeed() );
|
||||
} else {
|
||||
QTest::qt_asprintf(&buf, "<Environment>\n <QtVersion>%s</QtVersion>\n <QTestVersion>%s</QTestVersion>\n",
|
||||
qVersion(), QTEST_VERSION_STR );
|
||||
qVersion(), QT_VERSION_STR );
|
||||
}
|
||||
outputString(buf.constData());
|
||||
|
||||
|
|
|
@ -120,14 +120,14 @@ void QXmlTestLogger::startLogging()
|
|||
QTest::qt_asprintf(&buf,
|
||||
"<Environment>\n"
|
||||
" <QtVersion>%s</QtVersion>\n"
|
||||
" <QTestVersion>" QTEST_VERSION_STR "</QTestVersion>\n"
|
||||
" <QTestVersion>" QT_VERSION_STR "</QTestVersion>\n"
|
||||
" <RandomSeed>%d</RandomSeed>\n"
|
||||
"</Environment>\n", qVersion(), randomSeed);
|
||||
} else {
|
||||
QTest::qt_asprintf(&buf,
|
||||
"<Environment>\n"
|
||||
" <QtVersion>%s</QtVersion>\n"
|
||||
" <QTestVersion>" QTEST_VERSION_STR "</QTestVersion>\n"
|
||||
" <QTestVersion>" QT_VERSION_STR "</QTestVersion>\n"
|
||||
"</Environment>\n", qVersion());
|
||||
}
|
||||
outputString(buf.constData());
|
||||
|
@ -261,7 +261,7 @@ void QXmlTestLogger::addBenchmarkResult(const QBenchmarkResult &result)
|
|||
QTest::benchmarkResultFormatString(),
|
||||
quotedMetric.constData(),
|
||||
quotedTag.constData(),
|
||||
QByteArray::number(result.value).constData(), //no 64-bit qt_snprintf support
|
||||
QByteArray::number(result.value).constData(), //no 64-bit qsnprintf support
|
||||
result.iterations);
|
||||
outputString(buf.constData());
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue