We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 451d57d commit 956de5aCopy full SHA for 956de5a
src/utility/time/TimeService.cpp
@@ -192,6 +192,15 @@ unsigned long TimeService::getTimeFromString(const String& input)
192
* PRIVATE MEMBER FUNCTIONS
193
**************************************************************************************/
194
195
+bool TimeService::connected()
196
+{
197
+ if(_con_hdl == nullptr) {
198
+ return false;
199
+ } else {
200
+ return _con_hdl->getStatus() == NetworkConnectionState::CONNECTED;
201
+ }
202
+}
203
+
204
unsigned long TimeService::getRemoteTime()
205
{
206
#include "../../AIoTC_Config.h"
src/utility/time/TimeService.h
@@ -64,6 +64,7 @@ class TimeService
64
unsigned long _timezone_dst_until;
65
66
unsigned long getRemoteTime();
67
+ bool connected();
68
static bool isTimeValid(unsigned long const time);
69
70
};
0 commit comments