diff options
Diffstat (limited to 'common/domain/applicationdomaintype.cpp')
-rw-r--r-- | common/domain/applicationdomaintype.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/common/domain/applicationdomaintype.cpp b/common/domain/applicationdomaintype.cpp index 2a7f948..ff2990d 100644 --- a/common/domain/applicationdomaintype.cpp +++ b/common/domain/applicationdomaintype.cpp | |||
@@ -212,6 +212,12 @@ QVariant ApplicationDomainType::getProperty(const QByteArray &key) const | |||
212 | return mAdaptor->getProperty(key); | 212 | return mAdaptor->getProperty(key); |
213 | } | 213 | } |
214 | 214 | ||
215 | QVariantList ApplicationDomainType::getCollectedProperty(const QByteArray &key) const | ||
216 | { | ||
217 | Q_ASSERT(mAdaptor); | ||
218 | return mAdaptor->getProperty(key + "Collected").toList(); | ||
219 | } | ||
220 | |||
215 | void ApplicationDomainType::setProperty(const QByteArray &key, const QVariant &value) | 221 | void ApplicationDomainType::setProperty(const QByteArray &key, const QVariant &value) |
216 | { | 222 | { |
217 | Q_ASSERT(mAdaptor); | 223 | Q_ASSERT(mAdaptor); |
@@ -283,6 +289,11 @@ QVector<QByteArray> &ApplicationDomainType::aggregatedIds() | |||
283 | return mAggreatedIds; | 289 | return mAggreatedIds; |
284 | } | 290 | } |
285 | 291 | ||
292 | int ApplicationDomainType::count() const | ||
293 | { | ||
294 | return qMax(mAggreatedIds.size(), 1); | ||
295 | } | ||
296 | |||
286 | SinkResource::SinkResource(const QByteArray &identifier) | 297 | SinkResource::SinkResource(const QByteArray &identifier) |
287 | : ApplicationDomainType("", identifier, 0, QSharedPointer<BufferAdaptor>(new MemoryBufferAdaptor())) | 298 | : ApplicationDomainType("", identifier, 0, QSharedPointer<BufferAdaptor>(new MemoryBufferAdaptor())) |
288 | { | 299 | { |