History

GSF: Updates to C++ projects, including improvements to TimeSeriesPlatformLibrary

J. Ritchie Carroll committed 8 years ago

Commit b18ee4d1 parent 8f4fe8b39 files · +24148 −603Browse files

Showing the changes to Source/Libraries/TimeSeriesPlatformLibrary/Samples/AdvancedSubscribe.cpp (1 of 39 files). Show all

Unified · Split

Source/Libraries/TimeSeriesPlatformLibrary/Samples/AdvancedSubscribe.cpp+3−3
@@ -205,7 +205,7 @@ void ProcessMeasurements(DataSubscriber* source, vector<Measurement> newMeasurem · 204 unmodified lines
205205 {
206206 cout << Subscriber.GetTotalMeasurementsReceived() << " measurements received so far..." << endl;
207207
208− if (newMeasurements.size() > 0)
208+ if (!newMeasurements.empty())
209209 {
210210 if (TicksToString(timestamp, MaxTimestampSize, TimestampFormat, newMeasurements[0].Timestamp))
211211 cout << "Timestamp: " << string(timestamp) << endl;
@@ -238,13 +238,13 @@ void Resubscribe(DataSubscriber* source) · 26 unmodified lines
238238 }
239239
240240 // Callback which is called to display status messages from the subscriber.
241−void DisplayStatusMessage(DataSubscriber* source, string message)
241+void DisplayStatusMessage(DataSubscriber* source, const string& message)
242242 {
243243 cout << message << endl << endl;
244244 }
245245
246246 // Callback which is called to display error messages from the connector and subscriber.
247−void DisplayErrorMessage(DataSubscriber* source, string message)
247+void DisplayErrorMessage(DataSubscriber* source, const string& message)
248248 {
249249 cerr << message << endl << endl;
250250 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t