diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-11-14 16:22:07 +0100 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-11-14 16:22:07 +0100 |
commit | 175a49d623a5e37c1c20c80ed7f2077222f3c593 (patch) | |
tree | 0078863cf6c95b53095b247f55f7c3afb20e2f2d /common/queryrunner.cpp | |
parent | 3950140fadba01ea0a4a1a335ee7b6b653e45bf6 (diff) | |
download | sink-175a49d623a5e37c1c20c80ed7f2077222f3c593.tar.gz sink-175a49d623a5e37c1c20c80ed7f2077222f3c593.zip |
Hide the Query::limit
Diffstat (limited to 'common/queryrunner.cpp')
-rw-r--r-- | common/queryrunner.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/common/queryrunner.cpp b/common/queryrunner.cpp index 99f9c2d..b6c9aee 100644 --- a/common/queryrunner.cpp +++ b/common/queryrunner.cpp | |||
@@ -60,10 +60,10 @@ private: | |||
60 | 60 | ||
61 | template <class DomainType> | 61 | template <class DomainType> |
62 | QueryRunner<DomainType>::QueryRunner(const Sink::Query &query, const Sink::ResourceContext &context, const QByteArray &bufferType) | 62 | QueryRunner<DomainType>::QueryRunner(const Sink::Query &query, const Sink::ResourceContext &context, const QByteArray &bufferType) |
63 | : QueryRunnerBase(), mResourceContext(context), mResourceAccess(mResourceContext.resourceAccess()), mResultProvider(new ResultProvider<typename DomainType::Ptr>), mBatchSize(query.limit) | 63 | : QueryRunnerBase(), mResourceContext(context), mResourceAccess(mResourceContext.resourceAccess()), mResultProvider(new ResultProvider<typename DomainType::Ptr>), mBatchSize(query.limit()) |
64 | { | 64 | { |
65 | SinkTrace() << "Starting query. Is live:" << query.liveQuery() << " Limit: " << query.limit; | 65 | SinkTrace() << "Starting query. Is live:" << query.liveQuery() << " Limit: " << query.limit(); |
66 | if (query.limit && query.sortProperty().isEmpty()) { | 66 | if (query.limit() && query.sortProperty().isEmpty()) { |
67 | SinkWarning() << "A limited query without sorting is typically a bad idea."; | 67 | SinkWarning() << "A limited query without sorting is typically a bad idea."; |
68 | } | 68 | } |
69 | auto guardPtr = QPointer<QObject>(&guard); | 69 | auto guardPtr = QPointer<QObject>(&guard); |