From 4a14a6fade947aa830d3f21598a4a6ba7316b933 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Mon, 19 Sep 2016 18:55:21 +0200 Subject: Refactored the query part of the entity reader into DataStoreQuery. DataStoreQuery now encapsulates the low-level query that operates directly on the storage. It no longer has access to the resource buffers, and is instantiated by the type implementation, so we can specialize the query alogorithm per type, but not per resource. This will allow us to implement the threading queries for the mailtype. --- common/domain/folder.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'common/domain/folder.h') diff --git a/common/domain/folder.h b/common/domain/folder.h index 6e066e1..77edc8a 100644 --- a/common/domain/folder.h +++ b/common/domain/folder.h @@ -21,6 +21,7 @@ #include "applicationdomaintype.h" #include "storage.h" +#include "datastorequery.h" class ResultSet; class QByteArray; @@ -44,6 +45,7 @@ class TypeImplementation { public: typedef Sink::ApplicationDomain::Buffer::Folder Buffer; typedef Sink::ApplicationDomain::Buffer::FolderBuilder BufferBuilder; + static DataStoreQuery prepareQuery(const Sink::Query &query, Sink::Storage::Transaction &transaction); static QSet indexedProperties(); static ResultSet queryIndexes(const Sink::Query &query, const QByteArray &resourceInstanceIdentifier, QSet &appliedFilters, QByteArray &appliedSorting, Sink::Storage::Transaction &transaction); static void index(const QByteArray &identifier, const BufferAdaptor &bufferAdaptor, Sink::Storage::Transaction &transaction); -- cgit v1.2.3