From d6a01b3f82d626856001356c0875aa738a0346ac Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Tue, 4 Oct 2016 08:25:18 +0200 Subject: Support for subqueries. This allows us to match properties from a subquery. Unfortunately this also means that DataStoreQuery needs access to all type implementations to issue the subquery (for potentially another type). --- common/query.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'common/query.cpp') diff --git a/common/query.cpp b/common/query.cpp index 3de80d8..a43ef6c 100644 --- a/common/query.cpp +++ b/common/query.cpp @@ -62,6 +62,11 @@ bool Query::Comparator::matches(const QVariant &v) const return false; } return v.value().contains(value.toByteArray()); + case In: + if (!v.isValid()) { + return false; + } + return value.value().contains(v.toByteArray()); case Invalid: default: break; -- cgit v1.2.3