diff options
Diffstat (limited to 'common/clientapi.h')
-rw-r--r-- | common/clientapi.h | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/common/clientapi.h b/common/clientapi.h index f88eb5c..ff23da5 100644 --- a/common/clientapi.h +++ b/common/clientapi.h | |||
@@ -20,7 +20,7 @@ | |||
20 | 20 | ||
21 | #pragma once | 21 | #pragma once |
22 | 22 | ||
23 | #include "sinkcommon_export.h" | 23 | #include "sink_export.h" |
24 | #include <QString> | 24 | #include <QString> |
25 | #include <QSharedPointer> | 25 | #include <QSharedPointer> |
26 | 26 | ||
@@ -36,7 +36,7 @@ namespace Sink { | |||
36 | class ResourceAccess; | 36 | class ResourceAccess; |
37 | class Notification; | 37 | class Notification; |
38 | 38 | ||
39 | class SINKCOMMON_EXPORT Notifier { | 39 | class SINK_EXPORT Notifier { |
40 | public: | 40 | public: |
41 | Notifier(const QSharedPointer<ResourceAccess> &resourceAccess); | 41 | Notifier(const QSharedPointer<ResourceAccess> &resourceAccess); |
42 | Notifier(const QByteArray &resourceInstanceIdentifier); | 42 | Notifier(const QByteArray &resourceInstanceIdentifier); |
@@ -54,8 +54,8 @@ private: | |||
54 | */ | 54 | */ |
55 | namespace Store { | 55 | namespace Store { |
56 | 56 | ||
57 | QString SINKCOMMON_EXPORT storageLocation(); | 57 | QString SINK_EXPORT storageLocation(); |
58 | QByteArray SINKCOMMON_EXPORT resourceName(const QByteArray &instanceIdentifier); | 58 | QByteArray SINK_EXPORT resourceName(const QByteArray &instanceIdentifier); |
59 | 59 | ||
60 | enum Roles { | 60 | enum Roles { |
61 | DomainObjectRole = Qt::UserRole + 1, //Must be the same as in ModelResult | 61 | DomainObjectRole = Qt::UserRole + 1, //Must be the same as in ModelResult |
@@ -67,13 +67,13 @@ enum Roles { | |||
67 | * Asynchronusly load a dataset with tree structure information | 67 | * Asynchronusly load a dataset with tree structure information |
68 | */ | 68 | */ |
69 | template <class DomainType> | 69 | template <class DomainType> |
70 | QSharedPointer<QAbstractItemModel> SINKCOMMON_EXPORT loadModel(Query query); | 70 | QSharedPointer<QAbstractItemModel> SINK_EXPORT loadModel(Query query); |
71 | 71 | ||
72 | /** | 72 | /** |
73 | * Create a new entity. | 73 | * Create a new entity. |
74 | */ | 74 | */ |
75 | template <class DomainType> | 75 | template <class DomainType> |
76 | KAsync::Job<void> SINKCOMMON_EXPORT create(const DomainType &domainObject); | 76 | KAsync::Job<void> SINK_EXPORT create(const DomainType &domainObject); |
77 | 77 | ||
78 | /** | 78 | /** |
79 | * Modify an entity. | 79 | * Modify an entity. |
@@ -81,51 +81,51 @@ KAsync::Job<void> SINKCOMMON_EXPORT create(const DomainType &domainObject); | |||
81 | * This includes moving etc. since these are also simple settings on a property. | 81 | * This includes moving etc. since these are also simple settings on a property. |
82 | */ | 82 | */ |
83 | template <class DomainType> | 83 | template <class DomainType> |
84 | KAsync::Job<void> SINKCOMMON_EXPORT modify(const DomainType &domainObject); | 84 | KAsync::Job<void> SINK_EXPORT modify(const DomainType &domainObject); |
85 | 85 | ||
86 | /** | 86 | /** |
87 | * Remove an entity. | 87 | * Remove an entity. |
88 | */ | 88 | */ |
89 | template <class DomainType> | 89 | template <class DomainType> |
90 | KAsync::Job<void> SINKCOMMON_EXPORT remove(const DomainType &domainObject); | 90 | KAsync::Job<void> SINK_EXPORT remove(const DomainType &domainObject); |
91 | 91 | ||
92 | /** | 92 | /** |
93 | * Synchronize data to local cache. | 93 | * Synchronize data to local cache. |
94 | */ | 94 | */ |
95 | KAsync::Job<void> SINKCOMMON_EXPORT synchronize(const Sink::Query &query); | 95 | KAsync::Job<void> SINK_EXPORT synchronize(const Sink::Query &query); |
96 | 96 | ||
97 | /** | 97 | /** |
98 | * Removes a resource from disk. | 98 | * Removes a resource from disk. |
99 | */ | 99 | */ |
100 | void SINKCOMMON_EXPORT removeFromDisk(const QByteArray &resourceIdentifier); | 100 | void SINK_EXPORT removeFromDisk(const QByteArray &resourceIdentifier); |
101 | 101 | ||
102 | /** | 102 | /** |
103 | * Removes all resource data from disk. | 103 | * Removes all resource data from disk. |
104 | * | 104 | * |
105 | * This will not touch the configuration. All commands that that arrived at the resource before this command will be dropped. All commands that arrived later will be executed. | 105 | * This will not touch the configuration. All commands that that arrived at the resource before this command will be dropped. All commands that arrived later will be executed. |
106 | */ | 106 | */ |
107 | KAsync::Job<void> SINKCOMMON_EXPORT removeDataFromDisk(const QByteArray &resourceIdentifier); | 107 | KAsync::Job<void> SINK_EXPORT removeDataFromDisk(const QByteArray &resourceIdentifier); |
108 | 108 | ||
109 | template <class DomainType> | 109 | template <class DomainType> |
110 | KAsync::Job<DomainType> SINKCOMMON_EXPORT fetchOne(const Sink::Query &query); | 110 | KAsync::Job<DomainType> SINK_EXPORT fetchOne(const Sink::Query &query); |
111 | 111 | ||
112 | template <class DomainType> | 112 | template <class DomainType> |
113 | KAsync::Job<QList<typename DomainType::Ptr> > SINKCOMMON_EXPORT fetchAll(const Sink::Query &query); | 113 | KAsync::Job<QList<typename DomainType::Ptr> > SINK_EXPORT fetchAll(const Sink::Query &query); |
114 | 114 | ||
115 | template <class DomainType> | 115 | template <class DomainType> |
116 | KAsync::Job<QList<typename DomainType::Ptr> > SINKCOMMON_EXPORT fetch(const Sink::Query &query, int minimumAmount = 0); | 116 | KAsync::Job<QList<typename DomainType::Ptr> > SINK_EXPORT fetch(const Sink::Query &query, int minimumAmount = 0); |
117 | 117 | ||
118 | }; | 118 | }; |
119 | 119 | ||
120 | namespace Resources { | 120 | namespace Resources { |
121 | 121 | ||
122 | template <class DomainType> | 122 | template <class DomainType> |
123 | KAsync::Job<void> SINKCOMMON_EXPORT inspect(const Inspection &inspectionCommand); | 123 | KAsync::Job<void> SINK_EXPORT inspect(const Inspection &inspectionCommand); |
124 | 124 | ||
125 | /** | 125 | /** |
126 | * Shutdown resource. | 126 | * Shutdown resource. |
127 | */ | 127 | */ |
128 | KAsync::Job<void> SINKCOMMON_EXPORT shutdown(const QByteArray &resourceIdentifier); | 128 | KAsync::Job<void> SINK_EXPORT shutdown(const QByteArray &resourceIdentifier); |
129 | 129 | ||
130 | /** | 130 | /** |
131 | * Start resource. | 131 | * Start resource. |
@@ -134,17 +134,17 @@ KAsync::Job<void> SINKCOMMON_EXPORT shutdown(const QByteArray &resourceIdentifie | |||
134 | * This command is only necessary if a resource was shutdown previously, | 134 | * This command is only necessary if a resource was shutdown previously, |
135 | * otherwise the resource process will automatically start as necessary. | 135 | * otherwise the resource process will automatically start as necessary. |
136 | */ | 136 | */ |
137 | KAsync::Job<void> SINKCOMMON_EXPORT start(const QByteArray &resourceIdentifier); | 137 | KAsync::Job<void> SINK_EXPORT start(const QByteArray &resourceIdentifier); |
138 | 138 | ||
139 | /** | 139 | /** |
140 | * Flushes any pending messages to disk | 140 | * Flushes any pending messages to disk |
141 | */ | 141 | */ |
142 | KAsync::Job<void> SINKCOMMON_EXPORT flushMessageQueue(const QByteArrayList &resourceIdentifier); | 142 | KAsync::Job<void> SINK_EXPORT flushMessageQueue(const QByteArrayList &resourceIdentifier); |
143 | 143 | ||
144 | /** | 144 | /** |
145 | * Flushes any pending messages that haven't been replayed to the source. | 145 | * Flushes any pending messages that haven't been replayed to the source. |
146 | */ | 146 | */ |
147 | KAsync::Job<void> SINKCOMMON_EXPORT flushReplayQueue(const QByteArrayList &resourceIdentifier); | 147 | KAsync::Job<void> SINK_EXPORT flushReplayQueue(const QByteArrayList &resourceIdentifier); |
148 | 148 | ||
149 | } | 149 | } |
150 | 150 | ||