int main() {
{1, 1000},
"GenerateEvent",
const auto severity = input[0].getScalar<uint16_t>();
event.writeSeverity(severity);
event.trigger();
},
{
},
{}
);
}
static DateTime now() noexcept
Get current DateTime.
Create and trigger events.
High-level node class to access node attribute, browse and populate address space.
Node & writeEventNotifier(Bitmask< EventNotifier > eventNotifier)
Write the AttributeId::EventNotifier attribute of a node.
Node addMethod(const NodeId &id, std::string_view browseName, services::MethodCallback callback, Span< const Argument > inputArguments, Span< const Argument > outputArguments, const MethodAttributes &attributes={}, const NodeId &referenceType=ReferenceTypeId::HasComponent)
Add method.
void run()
Run the server's main loop. This method will block until Server::stop is called.
View to a contiguous sequence of objects, similar to std::span in C++20.