@@ -89,7 +89,8 using default_copier_t = typename default_copier<T>::type; | |||
|
89 | 89 | |
|
90 | 90 | template <class T, class D, class C> |
|
91 | 91 | struct is_default_manageable |
|
92 |
: public std::integral_constant<bool, |
|
|
92 | : public std::integral_constant<bool, | |
|
93 | std::is_same<D, default_deleter_t<T> >::value | |
|
93 | 94 |
|
|
94 | 95 | }; |
|
95 | 96 | } |
@@ -131,7 +132,8 public: | |||
|
131 | 132 | } |
|
132 | 133 | |
|
133 | 134 | template <class U> |
|
134 | impl_ptr(U *u, typename std::enable_if<std::is_convertible<U *, pointer>::value | |
|
135 | impl_ptr(U *u, | |
|
136 | typename std::enable_if<std::is_convertible<U *, pointer>::value | |
|
135 | 137 |
|
|
136 | 138 |
|
|
137 | 139 |
|
@@ -151,11 +153,11 public: | |||
|
151 | 153 | |
|
152 | 154 | #ifdef SPIMPL_HAS_AUTO_PTR |
|
153 | 155 | template <class U> |
|
154 | impl_ptr(std::auto_ptr<U> &&u, typename std::enable_if<std::is_convertible<U *, pointer>::value | |
|
156 | impl_ptr(std::auto_ptr<U> &&u, | |
|
157 | typename std::enable_if<std::is_convertible<U *, pointer>::value | |
|
155 | 158 |
|
|
156 | 159 |
|
|
157 | = dummy_t_()) SPIMPL_NOEXCEPT | |
|
158 | : ptr_(u.release(), &details::default_delete<T>), | |
|
160 | = dummy_t_()) SPIMPL_NOEXCEPT : ptr_(u.release(), &details::default_delete<T>), | |
|
159 | 161 | copier_(&details::default_copy<T>) |
|
160 | 162 | { |
|
161 | 163 | } |
@@ -49,14 +49,14 public: | |||
|
49 | 49 | DataSourceController::DataSourceController(QObject *parent) |
|
50 | 50 | : impl{spimpl::make_unique_impl<DataSourceControllerPrivate>()} |
|
51 | 51 | { |
|
52 |
qCDebug(LOG_DataSourceController()) |
|
|
53 | << QThread::currentThread(); | |
|
52 | qCDebug(LOG_DataSourceController()) | |
|
53 | << tr("DataSourceController construction") << QThread::currentThread(); | |
|
54 | 54 | } |
|
55 | 55 | |
|
56 | 56 | DataSourceController::~DataSourceController() |
|
57 | 57 | { |
|
58 |
qCDebug(LOG_DataSourceController()) |
|
|
59 | << QThread::currentThread(); | |
|
58 | qCDebug(LOG_DataSourceController()) | |
|
59 | << tr("DataSourceController destruction") << QThread::currentThread(); | |
|
60 | 60 | this->waitForFinish(); |
|
61 | 61 | } |
|
62 | 62 | |
@@ -126,8 +126,8 void DataSourceController::loadProductItem(const QUuid &dataSourceUid, | |||
|
126 | 126 | |
|
127 | 127 | void DataSourceController::initialize() |
|
128 | 128 | { |
|
129 |
qCDebug(LOG_DataSourceController()) |
|
|
130 | << QThread::currentThread(); | |
|
129 | qCDebug(LOG_DataSourceController()) | |
|
130 | << tr("DataSourceController init") << QThread::currentThread(); | |
|
131 | 131 | impl->m_WorkingMutex.lock(); |
|
132 | 132 | qCDebug(LOG_DataSourceController()) << tr("DataSourceController init END"); |
|
133 | 133 | } |
@@ -64,8 +64,8 void NetworkController::onProcessRequested(std::shared_ptr<QNetworkRequest> requ | |||
|
64 | 64 | impl->unlock(); |
|
65 | 65 | } |
|
66 | 66 | |
|
67 |
qCDebug(LOG_NetworkController()) |
|
|
68 |
|
|
|
67 | qCDebug(LOG_NetworkController()) | |
|
68 | << tr("NetworkController onReplyFinished END") << QThread::currentThread() << reply; | |
|
69 | 69 | }; |
|
70 | 70 | |
|
71 | 71 | auto onReplyProgress = [reply, request, this](qint64 bytesRead, qint64 totalBytes) { |
@@ -73,9 +73,9 void NetworkController::onProcessRequested(std::shared_ptr<QNetworkRequest> requ | |||
|
73 | 73 | // NOTE: a totalbytes of 0 can happened when a request has been aborted |
|
74 | 74 | if (totalBytes > 0) { |
|
75 | 75 | double progress = (bytesRead * 100.0) / totalBytes; |
|
76 |
qCDebug(LOG_NetworkController()) |
|
|
77 | << QThread::currentThread() << request.get() << reply | |
|
78 |
|
|
|
76 | qCDebug(LOG_NetworkController()) | |
|
77 | << tr("NetworkController onReplyProgress") << progress << QThread::currentThread() | |
|
78 | << request.get() << reply << bytesRead << totalBytes; | |
|
79 | 79 | impl->lockRead(); |
|
80 | 80 | auto it = impl->m_NetworkReplyToId.find(reply); |
|
81 | 81 | if (it != impl->m_NetworkReplyToId.cend()) { |
@@ -87,8 +87,8 void NetworkController::onProcessRequested(std::shared_ptr<QNetworkRequest> requ | |||
|
87 | 87 | impl->unlock(); |
|
88 | 88 | } |
|
89 | 89 | |
|
90 |
qCDebug(LOG_NetworkController()) |
|
|
91 |
|
|
|
90 | qCDebug(LOG_NetworkController()) | |
|
91 | << tr("NetworkController onReplyProgress END") << QThread::currentThread() << reply; | |
|
92 | 92 | } |
|
93 | 93 | }; |
|
94 | 94 | |
@@ -125,8 +125,8 void NetworkController::finalize() | |||
|
125 | 125 | void NetworkController::onReplyCanceled(QUuid identifier) |
|
126 | 126 | { |
|
127 | 127 | auto findReply = [identifier](const auto &entry) { return identifier == entry.second; }; |
|
128 |
qCDebug(LOG_NetworkController()) |
|
|
129 |
|
|
|
128 | qCDebug(LOG_NetworkController()) | |
|
129 | << tr("NetworkController onReplyCanceled") << QThread::currentThread() << identifier; | |
|
130 | 130 | |
|
131 | 131 | |
|
132 | 132 | impl->lockRead(); |
@@ -138,8 +138,8 void NetworkController::onReplyCanceled(QUuid identifier) | |||
|
138 | 138 | << QThread::currentThread() << identifier; |
|
139 | 139 | it->first->abort(); |
|
140 | 140 | } |
|
141 |
qCDebug(LOG_NetworkController()) |
|
|
142 | << QThread::currentThread(); | |
|
141 | qCDebug(LOG_NetworkController()) | |
|
142 | << tr("NetworkController onReplyCanceled END") << QThread::currentThread(); | |
|
143 | 143 | } |
|
144 | 144 | |
|
145 | 145 | void NetworkController::waitForFinish() |
@@ -265,8 +265,8 QVector<SqpRange> Variable::provideNotInCacheRangeList(const SqpRange &range) co | |||
|
265 | 265 | notInCache << SqpRange{impl->m_CacheRange.m_TEnd, range.m_TEnd}; |
|
266 | 266 | } |
|
267 | 267 | else { |
|
268 |
qCCritical(LOG_Variable()) |
|
|
269 |
|
|
|
268 | qCCritical(LOG_Variable()) | |
|
269 | << tr("Detection of unknown case.") << QThread::currentThread(); | |
|
270 | 270 | } |
|
271 | 271 | } |
|
272 | 272 | } |
@@ -305,8 +305,8 QVector<SqpRange> Variable::provideInCacheRangeList(const SqpRange &range) const | |||
|
305 | 305 | inCache << impl->m_CacheRange; |
|
306 | 306 | } |
|
307 | 307 | else { |
|
308 |
qCCritical(LOG_Variable()) |
|
|
309 |
|
|
|
308 | qCCritical(LOG_Variable()) | |
|
309 | << tr("Detection of unknown case.") << QThread::currentThread(); | |
|
310 | 310 | } |
|
311 | 311 | } |
|
312 | 312 | } |
@@ -49,8 +49,8 VariableAcquisitionWorker::VariableAcquisitionWorker(QObject *parent) | |||
|
49 | 49 | |
|
50 | 50 | VariableAcquisitionWorker::~VariableAcquisitionWorker() |
|
51 | 51 | { |
|
52 |
qCInfo(LOG_VariableAcquisitionWorker()) |
|
|
53 | << QThread::currentThread(); | |
|
52 | qCInfo(LOG_VariableAcquisitionWorker()) | |
|
53 | << tr("VariableAcquisitionWorker destruction") << QThread::currentThread(); | |
|
54 | 54 | this->waitForFinish(); |
|
55 | 55 | } |
|
56 | 56 | |
@@ -144,8 +144,8 void VariableAcquisitionWorker::abortProgressRequested(QUuid vIdentifier) | |||
|
144 | 144 | void VariableAcquisitionWorker::onVariableRetrieveDataInProgress(QUuid acqIdentifier, |
|
145 | 145 | double progress) |
|
146 | 146 | { |
|
147 |
qCDebug(LOG_VariableAcquisitionWorker()) |
|
|
148 | << acqIdentifier << progress; | |
|
147 | qCDebug(LOG_VariableAcquisitionWorker()) | |
|
148 | << tr("TORM: onVariableRetrieveDataInProgress ") << acqIdentifier << progress; | |
|
149 | 149 | impl->lockRead(); |
|
150 | 150 | auto aIdToARit = impl->m_AcqIdentifierToAcqRequestMap.find(acqIdentifier); |
|
151 | 151 | if (aIdToARit != impl->m_AcqIdentifierToAcqRequestMap.cend()) { |
@@ -170,15 +170,15 void VariableAcquisitionWorker::onVariableRetrieveDataInProgress(QUuid acqIdenti | |||
|
170 | 170 | |
|
171 | 171 | void VariableAcquisitionWorker::onVariableAcquisitionFailed(QUuid acqIdentifier) |
|
172 | 172 | { |
|
173 |
qCDebug(LOG_VariableAcquisitionWorker()) |
|
|
174 | << QThread::currentThread(); | |
|
173 | qCDebug(LOG_VariableAcquisitionWorker()) | |
|
174 | << tr("onVariableAcquisitionFailed") << QThread::currentThread(); | |
|
175 | 175 | impl->lockRead(); |
|
176 | 176 | auto it = impl->m_AcqIdentifierToAcqRequestMap.find(acqIdentifier); |
|
177 | 177 | if (it != impl->m_AcqIdentifierToAcqRequestMap.cend()) { |
|
178 | 178 | auto request = it->second; |
|
179 | 179 | impl->unlock(); |
|
180 |
qCInfo(LOG_VariableAcquisitionWorker()) |
|
|
181 |
|
|
|
180 | qCInfo(LOG_VariableAcquisitionWorker()) | |
|
181 | << tr("onVariableAcquisitionFailed") << acqIdentifier << request.m_vIdentifier | |
|
182 | 182 |
|
|
183 | 183 | emit variableCanceledRequested(request.m_vIdentifier); |
|
184 | 184 | } |
@@ -192,8 +192,8 void VariableAcquisitionWorker::onVariableDataAcquired(QUuid acqIdentifier, | |||
|
192 | 192 | std::shared_ptr<IDataSeries> dataSeries, |
|
193 | 193 | SqpRange dataRangeAcquired) |
|
194 | 194 | { |
|
195 |
qCDebug(LOG_VariableAcquisitionWorker()) |
|
|
196 | << acqIdentifier << dataRangeAcquired; | |
|
195 | qCDebug(LOG_VariableAcquisitionWorker()) | |
|
196 | << tr("TORM: onVariableDataAcquired on range ") << acqIdentifier << dataRangeAcquired; | |
|
197 | 197 | impl->lockWrite(); |
|
198 | 198 | auto aIdToARit = impl->m_AcqIdentifierToAcqRequestMap.find(acqIdentifier); |
|
199 | 199 | if (aIdToARit != impl->m_AcqIdentifierToAcqRequestMap.cend()) { |
@@ -258,8 +258,8 void VariableAcquisitionWorker::onExecuteRequest(QUuid acqIdentifier) | |||
|
258 | 258 | |
|
259 | 259 | void VariableAcquisitionWorker::initialize() |
|
260 | 260 | { |
|
261 |
qCDebug(LOG_VariableAcquisitionWorker()) |
|
|
262 | << QThread::currentThread(); | |
|
261 | qCDebug(LOG_VariableAcquisitionWorker()) | |
|
262 | << tr("VariableAcquisitionWorker init") << QThread::currentThread(); | |
|
263 | 263 | impl->m_WorkingMutex.lock(); |
|
264 | 264 | qCDebug(LOG_VariableAcquisitionWorker()) << tr("VariableAcquisitionWorker init END"); |
|
265 | 265 | } |
@@ -30,8 +30,8 VariableCacheController::VariableCacheController(QObject *parent) | |||
|
30 | 30 | void VariableCacheController::addDateTime(std::shared_ptr<Variable> variable, |
|
31 | 31 | const SqpRange &dateTime) |
|
32 | 32 | { |
|
33 |
qCDebug(LOG_VariableCacheController()) |
|
|
34 | << QThread::currentThread()->objectName(); | |
|
33 | qCDebug(LOG_VariableCacheController()) | |
|
34 | << "VariableCacheController::addDateTime" << QThread::currentThread()->objectName(); | |
|
35 | 35 | if (variable) { |
|
36 | 36 | auto findVariableIte = impl->m_VariableToSqpRangeListMap.find(variable); |
|
37 | 37 | if (findVariableIte == impl->m_VariableToSqpRangeListMap.end()) { |
@@ -104,8 +104,8 VariableCacheController::provideNotInCacheDateTimeList(std::shared_ptr<Variable> | |||
|
104 | 104 | QVector<SqpRange> |
|
105 | 105 | VariableCacheController::dateCacheList(std::shared_ptr<Variable> variable) const noexcept |
|
106 | 106 | { |
|
107 |
qCDebug(LOG_VariableCacheController()) |
|
|
108 | << QThread::currentThread()->objectName(); | |
|
107 | qCDebug(LOG_VariableCacheController()) | |
|
108 | << "VariableCacheController::dateCacheList" << QThread::currentThread()->objectName(); | |
|
109 | 109 | try { |
|
110 | 110 | return impl->m_VariableToSqpRangeListMap.at(variable); |
|
111 | 111 | } |
@@ -215,8 +215,8 void VariableCacheController::displayCache(std::shared_ptr<Variable> variable) c | |||
|
215 | 215 | { |
|
216 | 216 | auto variableDateTimeList = impl->m_VariableToSqpRangeListMap.find(variable); |
|
217 | 217 | if (variableDateTimeList != impl->m_VariableToSqpRangeListMap.end()) { |
|
218 |
qCInfo(LOG_VariableCacheController()) |
|
|
219 | << variableDateTimeList->second; | |
|
218 | qCInfo(LOG_VariableCacheController()) | |
|
219 | << tr("VariableCacheController::displayCache") << variableDateTimeList->second; | |
|
220 | 220 | } |
|
221 | 221 | else { |
|
222 | 222 | qCWarning(LOG_VariableCacheController()) |
@@ -148,8 +148,8 struct VariableController::VariableControllerPrivate { | |||
|
148 | 148 | VariableController::VariableController(QObject *parent) |
|
149 | 149 | : QObject{parent}, impl{spimpl::make_unique_impl<VariableControllerPrivate>(this)} |
|
150 | 150 | { |
|
151 |
qCDebug(LOG_VariableController()) |
|
|
152 | << QThread::currentThread(); | |
|
151 | qCDebug(LOG_VariableController()) | |
|
152 | << tr("VariableController construction") << QThread::currentThread(); | |
|
153 | 153 | |
|
154 | 154 | connect(impl->m_VariableModel, &VariableModel::abortProgessRequested, this, |
|
155 | 155 | &VariableController::onAbortProgressRequested); |
@@ -176,8 +176,8 VariableController::VariableController(QObject *parent) | |||
|
176 | 176 | |
|
177 | 177 | VariableController::~VariableController() |
|
178 | 178 | { |
|
179 |
qCDebug(LOG_VariableController()) |
|
|
180 | << QThread::currentThread(); | |
|
179 | qCDebug(LOG_VariableController()) | |
|
180 | << tr("VariableController destruction") << QThread::currentThread(); | |
|
181 | 181 | this->waitForFinish(); |
|
182 | 182 | } |
|
183 | 183 | |
@@ -296,8 +296,8 VariableController::createVariable(const QString &name, const QVariantHash &meta | |||
|
296 | 296 | void VariableController::onDateTimeOnSelection(const SqpRange &dateTime) |
|
297 | 297 | { |
|
298 | 298 | // TODO check synchronisation and Rescale |
|
299 |
qCDebug(LOG_VariableController()) |
|
|
300 | << QThread::currentThread()->objectName(); | |
|
299 | qCDebug(LOG_VariableController()) | |
|
300 | << "VariableController::onDateTimeOnSelection" << QThread::currentThread()->objectName(); | |
|
301 | 301 | auto selectedRows = impl->m_VariableSelectionModel->selectedRows(); |
|
302 | 302 | auto varRequestId = QUuid::createUuid(); |
|
303 | 303 | |
@@ -383,9 +383,9 void VariableController::onAbortAcquisitionRequested(QUuid vIdentifier) | |||
|
383 | 383 | |
|
384 | 384 | void VariableController::onAddSynchronizationGroupId(QUuid synchronizationGroupId) |
|
385 | 385 | { |
|
386 | qCDebug(LOG_VariableController()) << "TORM: VariableController::onAddSynchronizationGroupId" | |
|
387 | << QThread::currentThread()->objectName() | |
|
388 | << synchronizationGroupId; | |
|
386 | qCDebug(LOG_VariableController()) | |
|
387 | << "TORM: VariableController::onAddSynchronizationGroupId" | |
|
388 | << QThread::currentThread()->objectName() << synchronizationGroupId; | |
|
389 | 389 | auto vSynchroGroup = std::make_shared<VariableSynchronizationGroup>(); |
|
390 | 390 | impl->m_GroupIdToVariableSynchronizationGroupMap.insert( |
|
391 | 391 | std::make_pair(synchronizationGroupId, vSynchroGroup)); |
@@ -400,8 +400,8 void VariableController::onAddSynchronized(std::shared_ptr<Variable> variable, | |||
|
400 | 400 | QUuid synchronizationGroupId) |
|
401 | 401 | |
|
402 | 402 | { |
|
403 |
qCDebug(LOG_VariableController()) |
|
|
404 | << synchronizationGroupId; | |
|
403 | qCDebug(LOG_VariableController()) | |
|
404 | << "TORM: VariableController::onAddSynchronized" << synchronizationGroupId; | |
|
405 | 405 | auto varToVarIdIt = impl->m_VariableToIdentifierMap.find(variable); |
|
406 | 406 | if (varToVarIdIt != impl->m_VariableToIdentifierMap.cend()) { |
|
407 | 407 | auto groupIdToVSGIt |
@@ -506,8 +506,8 void VariableController::onRequestDataLoading(QVector<std::shared_ptr<Variable> | |||
|
506 | 506 | // Don't process already processed var |
|
507 | 507 | if (!variables.contains(var)) { |
|
508 | 508 | if (var != nullptr) { |
|
509 |
qCDebug(LOG_VariableController()) |
|
|
510 | << var->name(); | |
|
509 | qCDebug(LOG_VariableController()) | |
|
510 | << "processRequest synchro for" << var->name(); | |
|
511 | 511 | auto vSyncRangeRequested = computeSynchroRangeRequested( |
|
512 | 512 | var->range(), range, groupIdToOldRangeMap.at(gId)); |
|
513 | 513 | qCDebug(LOG_VariableController()) << "synchro RR" << vSyncRangeRequested; |
@@ -601,8 +601,8 void VariableController::VariableControllerPrivate::processRequest(std::shared_p | |||
|
601 | 601 | varProvider); |
|
602 | 602 | |
|
603 | 603 | if (!varRequestIdCanceled.isNull()) { |
|
604 |
qCDebug(LOG_VariableAcquisitionWorker()) |
|
|
605 | << varRequestIdCanceled; | |
|
604 | qCDebug(LOG_VariableAcquisitionWorker()) | |
|
605 | << tr("vsarRequestIdCanceled: ") << varRequestIdCanceled; | |
|
606 | 606 | cancelVariableRequest(varRequestIdCanceled); |
|
607 | 607 | } |
|
608 | 608 | } |
@@ -647,8 +647,8 VariableController::VariableControllerPrivate::findVariable(QUuid vIdentifier) | |||
|
647 | 647 | std::shared_ptr<IDataSeries> VariableController::VariableControllerPrivate::retrieveDataSeries( |
|
648 | 648 | const QVector<AcquisitionDataPacket> acqDataPacketVector) |
|
649 | 649 | { |
|
650 | qCDebug(LOG_VariableController()) << tr("TORM: retrieveDataSeries acqDataPacketVector size") | |
|
651 | << acqDataPacketVector.size(); | |
|
650 | qCDebug(LOG_VariableController()) | |
|
651 | << tr("TORM: retrieveDataSeries acqDataPacketVector size") << acqDataPacketVector.size(); | |
|
652 | 652 | std::shared_ptr<IDataSeries> dataSeries; |
|
653 | 653 | if (!acqDataPacketVector.isEmpty()) { |
|
654 | 654 | dataSeries = acqDataPacketVector[0].m_DateSeries; |
@@ -665,8 +665,8 void VariableController::VariableControllerPrivate::registerProvider( | |||
|
665 | 665 | std::shared_ptr<IDataProvider> provider) |
|
666 | 666 | { |
|
667 | 667 | if (m_ProviderSet.find(provider) == m_ProviderSet.end()) { |
|
668 |
qCDebug(LOG_VariableController()) |
|
|
669 |
|
|
|
668 | qCDebug(LOG_VariableController()) | |
|
669 | << tr("Registering of a new provider") << provider->objectName(); | |
|
670 | 670 | m_ProviderSet.insert(provider); |
|
671 | 671 | connect(provider.get(), &IDataProvider::dataProvided, m_VariableAcquisitionWorker.get(), |
|
672 | 672 | &VariableAcquisitionWorker::onVariableDataAcquired); |
@@ -772,8 +772,8 void VariableController::VariableControllerPrivate::updateVariableRequest(QUuid | |||
|
772 | 772 | (varIdToVarRequestMapIt != varIdToVarRequestMap.cend()) && processVariableUpdate; |
|
773 | 773 | ++varIdToVarRequestMapIt) { |
|
774 | 774 | processVariableUpdate &= varIdToVarRequestMapIt->second.m_CanUpdate; |
|
775 |
qCDebug(LOG_VariableController()) |
|
|
776 |
|
|
|
775 | qCDebug(LOG_VariableController()) | |
|
776 | << tr("updateVariableRequest") << processVariableUpdate; | |
|
777 | 777 | } |
|
778 | 778 | |
|
779 | 779 | if (processVariableUpdate) { |
@@ -783,10 +783,10 void VariableController::VariableControllerPrivate::updateVariableRequest(QUuid | |||
|
783 | 783 | auto &varRequest = varIdToVarRequestMapIt->second; |
|
784 | 784 | var->setRange(varRequest.m_RangeRequested); |
|
785 | 785 | var->setCacheRange(varRequest.m_CacheRangeRequested); |
|
786 |
qCDebug(LOG_VariableController()) |
|
|
787 |
|
|
|
788 |
qCDebug(LOG_VariableController()) |
|
|
789 |
|
|
|
786 | qCDebug(LOG_VariableController()) | |
|
787 | << tr("1: onDataProvided") << varRequest.m_RangeRequested; | |
|
788 | qCDebug(LOG_VariableController()) | |
|
789 | << tr("2: onDataProvided") << varRequest.m_CacheRangeRequested; | |
|
790 | 790 | var->mergeDataSeries(varRequest.m_DataSeries); |
|
791 | 791 | qCDebug(LOG_VariableController()) << tr("3: onDataProvided"); |
|
792 | 792 | |
@@ -805,11 +805,11 void VariableController::VariableControllerPrivate::updateVariableRequest(QUuid | |||
|
805 | 805 | } |
|
806 | 806 | |
|
807 | 807 | // cleaning varRequestId |
|
808 |
qCDebug(LOG_VariableController()) |
|
|
809 |
|
|
|
808 | qCDebug(LOG_VariableController()) | |
|
809 | << tr("0: erase REQUEST in MAP ?") << m_VarRequestIdToVarIdVarRequestMap.size(); | |
|
810 | 810 | m_VarRequestIdToVarIdVarRequestMap.erase(varRequestId); |
|
811 |
qCDebug(LOG_VariableController()) |
|
|
812 |
|
|
|
811 | qCDebug(LOG_VariableController()) | |
|
812 | << tr("1: erase REQUEST in MAP ?") << m_VarRequestIdToVarIdVarRequestMap.size(); | |
|
813 | 813 | } |
|
814 | 814 | } |
|
815 | 815 | else { |
@@ -18,21 +18,21 public: | |||
|
18 | 18 | VisualizationController::VisualizationController(QObject *parent) |
|
19 | 19 | : impl{spimpl::make_unique_impl<VisualizationControllerPrivate>()} |
|
20 | 20 | { |
|
21 |
qCDebug(LOG_VisualizationController()) |
|
|
22 | << QThread::currentThread(); | |
|
21 | qCDebug(LOG_VisualizationController()) | |
|
22 | << tr("VisualizationController construction") << QThread::currentThread(); | |
|
23 | 23 | } |
|
24 | 24 | |
|
25 | 25 | VisualizationController::~VisualizationController() |
|
26 | 26 | { |
|
27 |
qCDebug(LOG_VisualizationController()) |
|
|
28 | << QThread::currentThread(); | |
|
27 | qCDebug(LOG_VisualizationController()) | |
|
28 | << tr("VisualizationController destruction") << QThread::currentThread(); | |
|
29 | 29 | this->waitForFinish(); |
|
30 | 30 | } |
|
31 | 31 | |
|
32 | 32 | void VisualizationController::initialize() |
|
33 | 33 | { |
|
34 |
qCDebug(LOG_VisualizationController()) |
|
|
35 | << QThread::currentThread(); | |
|
34 | qCDebug(LOG_VisualizationController()) | |
|
35 | << tr("VisualizationController init") << QThread::currentThread(); | |
|
36 | 36 | impl->m_WorkingMutex.lock(); |
|
37 | 37 | qCDebug(LOG_VisualizationController()) << tr("VisualizationController init END"); |
|
38 | 38 | } |
@@ -267,9 +267,9 void VisualizationGraphWidget::onGraphMenuRequested(const QPoint &pos) noexcept | |||
|
267 | 267 | |
|
268 | 268 | void VisualizationGraphWidget::onRangeChanged(const QCPRange &t1, const QCPRange &t2) |
|
269 | 269 | { |
|
270 |
qCDebug(LOG_VisualizationGraphWidget()) |
|
|
271 | << QThread::currentThread()->objectName() << "DoAcqui" | |
|
272 | << impl->m_DoAcquisition; | |
|
270 | qCDebug(LOG_VisualizationGraphWidget()) | |
|
271 | << tr("TORM: VisualizationGraphWidget::onRangeChanged") | |
|
272 | << QThread::currentThread()->objectName() << "DoAcqui" << impl->m_DoAcquisition; | |
|
273 | 273 | |
|
274 | 274 | auto graphRange = SqpRange{t1.lower, t1.upper}; |
|
275 | 275 | auto oldGraphRange = SqpRange{t2.lower, t2.upper}; |
@@ -127,10 +127,10 VisualizationGraphWidget *VisualizationZoneWidget::createGraph(std::shared_ptr<V | |||
|
127 | 127 | graphChildRange.m_TStart += deltaLeft; |
|
128 | 128 | graphChildRange.m_TEnd -= deltaRight; |
|
129 | 129 | qCDebug(LOG_VisualizationZoneWidget()) << tr("TORM: ZoomIn"); |
|
130 |
qCDebug(LOG_VisualizationZoneWidget()) |
|
|
131 | << deltaLeft; | |
|
132 |
qCDebug(LOG_VisualizationZoneWidget()) |
|
|
133 | << deltaRight; | |
|
130 | qCDebug(LOG_VisualizationZoneWidget()) | |
|
131 | << tr("TORM: deltaLeft") << deltaLeft; | |
|
132 | qCDebug(LOG_VisualizationZoneWidget()) | |
|
133 | << tr("TORM: deltaRight") << deltaRight; | |
|
134 | 134 | qCDebug(LOG_VisualizationZoneWidget()) |
|
135 | 135 | << tr("TORM: dt") << graphRange.m_TEnd - graphRange.m_TStart; |
|
136 | 136 | |
@@ -141,10 +141,10 VisualizationGraphWidget *VisualizationZoneWidget::createGraph(std::shared_ptr<V | |||
|
141 | 141 | qCDebug(LOG_VisualizationZoneWidget()) << tr("TORM: ZoomOut"); |
|
142 | 142 | auto deltaLeft = oldGraphRange.m_TStart - graphRange.m_TStart; |
|
143 | 143 | auto deltaRight = graphRange.m_TEnd - oldGraphRange.m_TEnd; |
|
144 |
qCDebug(LOG_VisualizationZoneWidget()) |
|
|
145 | << deltaLeft; | |
|
146 |
qCDebug(LOG_VisualizationZoneWidget()) |
|
|
147 | << deltaRight; | |
|
144 | qCDebug(LOG_VisualizationZoneWidget()) | |
|
145 | << tr("TORM: deltaLeft") << deltaLeft; | |
|
146 | qCDebug(LOG_VisualizationZoneWidget()) | |
|
147 | << tr("TORM: deltaRight") << deltaRight; | |
|
148 | 148 | qCDebug(LOG_VisualizationZoneWidget()) |
|
149 | 149 | << tr("TORM: dt") << graphRange.m_TEnd - graphRange.m_TStart; |
|
150 | 150 | graphChildRange.m_TStart -= deltaLeft; |
@@ -179,10 +179,10 VisualizationGraphWidget *VisualizationZoneWidget::createGraph(std::shared_ptr<V | |||
|
179 | 179 | break; |
|
180 | 180 | } |
|
181 | 181 | graphChild->enableAcquisition(false); |
|
182 |
qCDebug(LOG_VisualizationZoneWidget()) |
|
|
183 |
|
|
|
184 |
qCDebug(LOG_VisualizationZoneWidget()) |
|
|
185 | << graphChildRange; | |
|
182 | qCDebug(LOG_VisualizationZoneWidget()) | |
|
183 | << tr("TORM: Range before: ") << graphChild->graphRange(); | |
|
184 | qCDebug(LOG_VisualizationZoneWidget()) | |
|
185 | << tr("TORM: Range after : ") << graphChildRange; | |
|
186 | 186 | qCDebug(LOG_VisualizationZoneWidget()) |
|
187 | 187 | << tr("TORM: child dt") << graphChildRange.m_TEnd - graphChildRange.m_TStart; |
|
188 | 188 | graphChild->setGraphRange(graphChildRange); |
@@ -1574,10 +1574,7 void QCPLayerable::applyAntialiasingHint(QCPPainter *painter, bool localAntialia | |||
|
1574 | 1574 | |
|
1575 | 1575 | \see initializeParentPlot |
|
1576 | 1576 | */ |
|
1577 | void QCPLayerable::parentPlotInitialized(QCustomPlot *parentPlot) | |
|
1578 | { | |
|
1579 | Q_UNUSED(parentPlot) | |
|
1580 | } | |
|
1577 | void QCPLayerable::parentPlotInitialized(QCustomPlot *parentPlot){Q_UNUSED(parentPlot)} | |
|
1581 | 1578 | |
|
1582 | 1579 | /*! \internal |
|
1583 | 1580 | |
@@ -9394,12 +9391,14 void QCPAxisPainterPrivate::draw(QCPPainter *painter) | |||
|
9394 | 9391 | painter->setBrush(QBrush(basePen.color())); |
|
9395 | 9392 | QCPVector2D baseLineVector(baseLine.dx(), baseLine.dy()); |
|
9396 | 9393 | if (lowerEnding.style() != QCPLineEnding::esNone) |
|
9397 |
lowerEnding.draw(painter, |
|
|
9394 | lowerEnding.draw(painter, | |
|
9395 | QCPVector2D(baseLine.p1()) | |
|
9398 | 9396 | - baseLineVector.normalized() * lowerEnding.realLength() |
|
9399 | 9397 | * (lowerEnding.inverted() ? -1 : 1), |
|
9400 | 9398 | -baseLineVector); |
|
9401 | 9399 | if (upperEnding.style() != QCPLineEnding::esNone) |
|
9402 |
upperEnding.draw(painter, |
|
|
9400 | upperEnding.draw(painter, | |
|
9401 | QCPVector2D(baseLine.p2()) | |
|
9403 | 9402 | + baseLineVector.normalized() * upperEnding.realLength() |
|
9404 | 9403 | * (upperEnding.inverted() ? -1 : 1), |
|
9405 | 9404 | baseLineVector); |
@@ -16630,7 +16629,8 void QCPColorGradient::updateColorBuffer() | |||
|
16630 | 16629 | hue -= 1.0; |
|
16631 | 16630 | if (useAlpha) { |
|
16632 | 16631 | const QRgb rgb |
|
16633 |
= QColor::fromHsvF(hue, |
|
|
16632 | = QColor::fromHsvF(hue, | |
|
16633 | (1 - t) * lowHsv.saturationF() | |
|
16634 | 16634 | + t * highHsv.saturationF(), |
|
16635 | 16635 | (1 - t) * lowHsv.valueF() + t * highHsv.valueF()) |
|
16636 | 16636 | .rgb(); |
@@ -16640,7 +16640,8 void QCPColorGradient::updateColorBuffer() | |||
|
16640 | 16640 | } |
|
16641 | 16641 | else { |
|
16642 | 16642 | mColorBuffer[i] |
|
16643 |
= QColor::fromHsvF(hue, |
|
|
16643 | = QColor::fromHsvF(hue, | |
|
16644 | (1 - t) * lowHsv.saturationF() | |
|
16644 | 16645 | + t * highHsv.saturationF(), |
|
16645 | 16646 | (1 - t) * lowHsv.valueF() + t * highHsv.valueF()) |
|
16646 | 16647 | .rgb(); |
@@ -19998,10 +19999,12 void QCPColorScale::update(UpdatePhase phase) | |||
|
19998 | 19999 | switch (phase) { |
|
19999 | 20000 | case upMargins: { |
|
20000 | 20001 | if (mType == QCPAxis::atBottom || mType == QCPAxis::atTop) { |
|
20001 |
setMaximumSize(QWIDGETSIZE_MAX, |
|
|
20002 |
|
|
|
20003 |
|
|
|
20004 | setMinimumSize(0, mBarWidth + mAxisRect.data()->margins().top() | |
|
20002 | setMaximumSize(QWIDGETSIZE_MAX, | |
|
20003 | mBarWidth + mAxisRect.data()->margins().top() | |
|
20004 | + mAxisRect.data()->margins().bottom() + margins().top() | |
|
20005 | + margins().bottom()); | |
|
20006 | setMinimumSize(0, | |
|
20007 | mBarWidth + mAxisRect.data()->margins().top() | |
|
20005 | 20008 | + mAxisRect.data()->margins().bottom() + margins().top() |
|
20006 | 20009 | + margins().bottom()); |
|
20007 | 20010 | } |
@@ -83,8 +83,8 void AmdaProvider::requestDataLoading(QUuid acqIdentifier, const DataProviderPar | |||
|
83 | 83 | const auto times = parameters.m_Times; |
|
84 | 84 | const auto data = parameters.m_Data; |
|
85 | 85 | for (const auto &dateTime : qAsConst(times)) { |
|
86 | qCDebug(LOG_AmdaProvider()) << tr("TORM AmdaProvider::requestDataLoading ") << acqIdentifier | |
|
87 | << dateTime; | |
|
86 | qCDebug(LOG_AmdaProvider()) | |
|
87 | << tr("TORM AmdaProvider::requestDataLoading ") << acqIdentifier << dateTime; | |
|
88 | 88 | this->retrieveData(acqIdentifier, dateTime, data); |
|
89 | 89 | |
|
90 | 90 | |
@@ -203,8 +203,8 void AmdaProvider::retrieveData(QUuid token, const SqpRange &dateTime, const QVa | |||
|
203 | 203 | emit dataProvidedFailed(dataId); |
|
204 | 204 | } |
|
205 | 205 | } |
|
206 | qCDebug(LOG_AmdaProvider()) << tr("acquisition requests erase because of finishing") | |
|
207 | << dataId; | |
|
206 | qCDebug(LOG_AmdaProvider()) | |
|
207 | << tr("acquisition requests erase because of finishing") << dataId; | |
|
208 | 208 | m_AcqIdToRequestProgressMap.erase(dataId); |
|
209 | 209 | } |
|
210 | 210 | else { |
@@ -142,14 +142,14 void TestAmdaParser::testReadJson_data() | |||
|
142 | 142 | QTest::newRow("Valid file") << QStringLiteral("ValidFile1.json") << validResults1(); |
|
143 | 143 | |
|
144 | 144 | // Invalid files |
|
145 |
QTest::newRow("Invalid file (unexisting file)") |
|
|
146 | << invalidResults(); | |
|
147 |
QTest::newRow("Invalid file (two root objects)") |
|
|
148 | << invalidResults(); | |
|
149 |
QTest::newRow("Invalid file (wrong root key)") |
|
|
150 | << invalidResults(); | |
|
151 |
QTest::newRow("Invalid file (wrong root type)") |
|
|
152 | << invalidResults(); | |
|
145 | QTest::newRow("Invalid file (unexisting file)") | |
|
146 | << QStringLiteral("UnexistingFile.json") << invalidResults(); | |
|
147 | QTest::newRow("Invalid file (two root objects)") | |
|
148 | << QStringLiteral("TwoRootsFile.json") << invalidResults(); | |
|
149 | QTest::newRow("Invalid file (wrong root key)") | |
|
150 | << QStringLiteral("WrongRootKey.json") << invalidResults(); | |
|
151 | QTest::newRow("Invalid file (wrong root type)") | |
|
152 | << QStringLiteral("WrongRootType.json") << invalidResults(); | |
|
153 | 153 | } |
|
154 | 154 | |
|
155 | 155 | void TestAmdaParser::testReadJson() |
@@ -229,11 +229,11 void TestAmdaResultParser::testReadScalarTxt_data() | |||
|
229 | 229 | QVector<QDateTime>{}, QVector<double>{}}; |
|
230 | 230 | |
|
231 | 231 | // Invalid files |
|
232 |
QTest::newRow("Invalid file (unexisting file)") |
|
|
233 | << ExpectedResults<ScalarSeries>{}; | |
|
232 | QTest::newRow("Invalid file (unexisting file)") | |
|
233 | << QStringLiteral("UnexistingFile.txt") << ExpectedResults<ScalarSeries>{}; | |
|
234 | 234 | |
|
235 |
QTest::newRow("Invalid file (file not found on server)") |
|
|
236 | << ExpectedResults<ScalarSeries>{}; | |
|
235 | QTest::newRow("Invalid file (file not found on server)") | |
|
236 | << QStringLiteral("FileNotFound.txt") << ExpectedResults<ScalarSeries>{}; | |
|
237 | 237 | } |
|
238 | 238 | |
|
239 | 239 | void TestAmdaResultParser::testReadScalarTxt() |
@@ -171,8 +171,8 void CosinusProvider::requestDataLoading(QUuid acqIdentifier, | |||
|
171 | 171 | { |
|
172 | 172 | // TODO: Add Mutex |
|
173 | 173 | m_VariableToEnableProvider[acqIdentifier] = true; |
|
174 | qCDebug(LOG_CosinusProvider()) << "TORM: CosinusProvider::requestDataLoading" | |
|
175 |
|
|
|
174 | qCDebug(LOG_CosinusProvider()) | |
|
175 | << "TORM: CosinusProvider::requestDataLoading" << QThread::currentThread()->objectName(); | |
|
176 | 176 | // NOTE: Try to use multithread if possible |
|
177 | 177 | const auto times = parameters.m_Times; |
|
178 | 178 |
General Comments 0
You need to be logged in to leave comments.
Login now