#include <iostream>
int main() {
client.
connect(
"opc.tcp://localhost:4840");
std::cout <<
"Server date (UTC): " << dt.
format(
"%Y-%m-%d %H:%M:%S") << std::endl;
}
void connect(std::string_view endpointUrl)
Connect to the selected server.
UA_DateTime wrapper class.
std::string format(std::string_view format, bool localtime=false) const
Convert to string with given format (same format codes as strftime).
High-level node class to access node attribute, browse and populate address space.
T readValueScalar()
Read scalar value from variable node.
@ Server_ServerStatus_CurrentTime