Showing the changes to Source/Libraries/TimeSeriesPlatformLibrary/Samples/SubscriberHandler.cpp (1 of 10 files). Show all
Unified · Split
| @@ -32,9 +32,9 @@ using namespace std; · 31 unmodified lines | ||
| 32 | 32 | using namespace GSF; |
| 33 | 33 | using namespace GSF::TimeSeries; |
| 34 | 34 | |
| 35 | −SubscriberHandler::SubscriberHandler(const string& name) | |
| 35 | +SubscriberHandler::SubscriberHandler(string name) : | |
| 36 | + m_name(std::move(name)) | |
| 36 | 37 | { |
| 37 | − m_name = name; | |
| 38 | 38 | } |
| 39 | 39 | |
| 40 | 40 | SubscriptionInfo SubscriberHandler::CreateSubscriptionInfo() |
| @@ -153,9 +153,9 @@ void SubscriberHandler::ReceivedNewMeasurements(const vector<MeasurementPtr>& me · 112 unmodified lines | ||
| 153 | 153 | |
| 154 | 154 | static long processCount = 0; |
| 155 | 155 | static char timestamp[MaxTimestampSize]; |
| 156 | − static const long interval = 5 * 60; | |
| 156 | + static const long interval = 10 * 60; | |
| 157 | 157 | const long measurementCount = measurements.size(); |
| 158 | − const bool showMessage = true; // (processCount + measurementCount >= (processCount / interval + 1) * interval); | |
| 158 | + const bool showMessage = (processCount + measurementCount >= (processCount / interval + 1) * interval); | |
| 159 | 159 | |
| 160 | 160 | processCount += measurementCount; |
| 161 | 161 | |
| @@ -194,8 +194,7 @@ void SubscriberHandler::HistoricalReadComplete() · 32 unmodified lines | ||
| 194 | 194 | |
| 195 | 195 | void SubscriberHandler::ConnectionEstablished() |
| 196 | 196 | { |
| 197 | − StatusMessage("Connection established."); | |
| 198 | − | |
| 197 | + StatusMessage("Connection established."); | |
| 199 | 198 | } |
| 200 | 199 | |
| 201 | 200 | void SubscriberHandler::ConnectionTerminated() |