open62541pp 0.16.0
C++ wrapper of open62541
|
Typedefs | |
template<typename T , typename... Ts> | |
using | IsOneOf = std::disjunction<std::is_same<T, Ts>...> |
template<typename T > | |
using | MemberTypeT = typename MemberType<T>::type |
template<typename T , typename U > | |
using | EnableIfEqualityComparable |
Enumerations | |
enum class | ClientState |
Functions | |
UA_DataTypeMember | createDataTypeMember (const char *memberName, const UA_DataType &memberType, uint8_t padding, bool isArray, bool isOptional) noexcept |
UA_DataType | createDataType (const char *typeName, UA_NodeId typeId, UA_NodeId binaryEncodingId, uint16_t memSize, uint8_t typeKind, bool pointerFree, bool overlayable, uint32_t membersSize, DataTypeMember *members) noexcept |
UA_DataTypeArray | createDataTypeArray (Span< const DataType > types, const UA_DataTypeArray *next=nullptr) noexcept |
template<auto memberPtr> | |
const UA_DataType & | getMemberDataType () |
template<typename T , typename TMember > | |
size_t | offsetOfMember (TMember T::*member) |
UA_ClientConfig * | getConfig (UA_Client *client) noexcept |
UA_Logger * | getLogger (UA_ClientConfig *config) noexcept |
ClientContext * | getContext (UA_Client *client) noexcept |
ClientContext & | getContext (Client &client) noexcept |
ExceptionCatcher * | getExceptionCatcher (UA_Client *client) noexcept |
ExceptionCatcher & | getExceptionCatcher (Client &client) noexcept |
UA_Client * | getHandle (Client &client) noexcept |
template<typename F , typename... Args> | |
auto | tryInvoke (F &&func, Args &&... args) noexcept -> typename ResultType< std::invoke_result_t< F, Args... > >::Type |
UA_ServerConfig * | getConfig (UA_Server *server) noexcept |
UA_Logger * | getLogger (UA_ServerConfig *config) noexcept |
ServerContext * | getContext (UA_Server *server) noexcept |
ServerContext & | getContext (Server &server) noexcept |
ExceptionCatcher * | getExceptionCatcher (UA_Server *server) noexcept |
ExceptionCatcher & | getExceptionCatcher (Server &server) noexcept |
UA_Server * | getHandle (Server &server) noexcept |
UA_String | toNativeString (std::string_view src) noexcept |
UA_String | allocNativeString (std::string_view src) |
std::string_view | toStringView (const UA_String &src) noexcept |
std::string | toString (const UA_String &src) |
std::string | toString (const char *format, va_list args) |
std::string | toString (const char *format,...) |
template<typename... Ts> | |
Overload (Ts...) -> Overload< Ts... > | |
template<typename T , typename = std::enable_if_t<std::is_enum_v<T>>> | |
auto | toNative (T value) noexcept |
auto | toNative (std::string_view value) |
template<typename T , typename = std::enable_if_t<isWrapper<T>>> | |
auto | toNative (T &&value) |
template<typename T > | |
auto * | toNativeArray (Span< const T > array) |
template<typename T > | |
constexpr bool | isBorrowed (const T &) noexcept |
constexpr bool | isBorrowed (const UA_Variant &native) noexcept |
constexpr bool | isBorrowed (const UA_DataValue &native) noexcept |
constexpr bool | isBorrowed (const UA_ExtensionObject &native) noexcept |
template<typename T > | |
constexpr bool | isValidTypeCombination (const UA_DataType &type) |
template<typename T > | |
constexpr void | clear (T &native, const UA_DataType &type) noexcept |
template<typename T > | |
void | deallocate (T *native, const UA_DataType &type) noexcept |
template<typename T > | |
T * | allocate (const UA_DataType &type) |
template<typename T > | |
auto | allocateUniquePtr (const UA_DataType &type) |
template<typename T > | |
constexpr T | copy (const T &src, const UA_DataType &type) noexcept(isPointerFree< T >) |
template<typename T > | |
void | deallocateArray (T *array, size_t size, const UA_DataType &type) noexcept |
template<typename T > | |
T * | allocateArray (size_t size, const UA_DataType &type) |
template<typename T > | |
auto | allocateArrayUniquePtr (size_t size, const UA_DataType &type) |
template<typename T > | |
T * | copyArray (const T *src, size_t size, const UA_DataType &type) |
template<typename T > | |
void | resizeArray (T *&array, size_t &size, size_t newSize, const UA_DataType &type) |
constexpr bool | isGood (UA_StatusCode code) noexcept |
constexpr bool | isUncertain (UA_StatusCode code) noexcept |
constexpr bool | isBad (UA_StatusCode code) noexcept |
UA_StatusCode | getStatusCode (std::exception_ptr eptr) noexcept |
void | clear (UA_AccessControl &ac) noexcept |
void | clear (UA_Logger &logger) noexcept |
Variables | |
constexpr size_t | clientStateCount = 4 |
template<typename T > | |
constexpr bool | isPointerFree |
template<typename T > | |
constexpr bool | isConvertibleType = IsConvertibleType<T>::value |
template<typename T > | |
constexpr bool | isRegisteredType = IsRegisteredType<T>::value |
template<typename T > | |
constexpr bool | isTypeWrapper = IsTypeWrapper<T>::value |
template<typename T > | |
constexpr bool | isWrapper = IsWrapper<T>::value |
using opcua::detail::IsOneOf = std::disjunction<std::is_same<T, Ts>...> |
Definition at line 19 of file traits.hpp.
using opcua::detail::MemberTypeT = typename MemberType<T>::type |
Definition at line 31 of file traits.hpp.
using opcua::detail::EnableIfEqualityComparable |
|
strong |
Enumerator | |
---|---|
Disconnected | |
Connected | |
SessionActivated | |
SessionClosed |
Definition at line 21 of file client_context.hpp.
|
nodiscardnoexcept |
|
nodiscardnoexcept |
|
nodiscardnoexcept |
const UA_DataType & opcua::detail::getMemberDataType | ( | ) |
Definition at line 178 of file datatype.hpp.
size_t opcua::detail::offsetOfMember | ( | TMember T::* | member | ) |
Definition at line 185 of file datatype.hpp.
Referenced by opcua::DataTypeBuilder< T, Tag, U >::addField(), and opcua::DataTypeBuilder< T, Tag, U >::addUnionField().
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
Referenced by opcua::services::createMonitoredItemsDataChangeAsync(), opcua::services::createMonitoredItemsEventAsync(), opcua::services::deleteMonitoredItemsAsync(), opcua::services::deleteSubscriptionsAsync(), opcua::services::modifyMonitoredItemsAsync(), opcua::services::modifySubscriptionAsync(), opcua::services::detail::sendRequest(), and opcua::services::detail::sendRequestAsync().
|
noexcept |
Invoke a function and capture its Result (value or status code).
This is especially useful for C-API callbacks, that are executed within the open62541 event loop.
Definition at line 31 of file result_utils.hpp.
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
Convert std::string_view to UA_String (no copy)
Referenced by opcua::services::detail::createAddNodesItem().
|
nodiscard |
Allocate UA_String from std::string_view.
Referenced by opcua::ExpandedNodeId::ExpandedNodeId(), opcua::LocalizedText::LocalizedText(), opcua::NodeId::NodeId(), opcua::QualifiedName::QualifiedName(), and toNative().
|
inlinenoexcept |
Convert UA_String to std::string_view Can be marked noexcept: https://stackoverflow.com/a/62061549/9967707.
Definition at line 19 of file string_utils.hpp.
Referenced by opcua::LocalizedText::getLocale(), opcua::QualifiedName::getName(), opcua::ExpandedNodeId::getNamespaceUri(), opcua::LocalizedText::getText(), and toString().
|
inline |
Convert UA_String to std::string.
Definition at line 27 of file string_utils.hpp.
Referenced by toString().
std::string opcua::detail::toString | ( | const char * | format, |
va_list | args ) |
Convert format string with args to std::string.
|
inline |
Definition at line 35 of file string_utils.hpp.
opcua::detail::Overload | ( | Ts... | ) | -> Overload< Ts... > |
|
nodiscardnoexcept |
Definition at line 15 of file types_conversion.hpp.
Referenced by opcua::EnumValueType::EnumValueType(), and opcua::RequestHeader::RequestHeader().
|
inlinenodiscard |
Definition at line 19 of file types_conversion.hpp.
|
nodiscard |
Definition at line 24 of file types_conversion.hpp.
|
nodiscard |
Definition at line 32 of file types_conversion.hpp.
|
constexprnoexcept |
Definition at line 36 of file types_handling.hpp.
Referenced by clear().
|
constexprnoexcept |
Definition at line 40 of file types_handling.hpp.
|
constexprnoexcept |
Definition at line 44 of file types_handling.hpp.
|
constexprnoexcept |
Definition at line 48 of file types_handling.hpp.
|
constexpr |
Definition at line 53 of file types_handling.hpp.
Referenced by allocate(), allocateArray(), clear(), copy(), deallocate(), and deallocateArray().
|
constexprnoexcept |
Definition at line 62 of file types_handling.hpp.
Referenced by opcua::TypeWrapper< T, typeIndex >::clear().
|
noexcept |
Definition at line 75 of file types_handling.hpp.
Referenced by allocateUniquePtr().
|
nodiscard |
Definition at line 81 of file types_handling.hpp.
Referenced by allocateUniquePtr(), and opcua::ExtensionObject::fromDecodedCopy().
|
nodiscard |
Definition at line 91 of file types_handling.hpp.
|
nodiscardconstexprnoexcept |
Definition at line 97 of file types_handling.hpp.
Referenced by copyArray(), opcua::TypeWrapper< T, typeIndex >::operator=(), and opcua::TypeWrapper< T, typeIndex >::operator=().
|
noexcept |
Definition at line 111 of file types_handling.hpp.
Referenced by allocateArrayUniquePtr(), and resizeArray().
|
nodiscard |
Definition at line 117 of file types_handling.hpp.
Referenced by allocateArrayUniquePtr(), copyArray(), and resizeArray().
|
nodiscard |
Definition at line 127 of file types_handling.hpp.
|
nodiscard |
Definition at line 133 of file types_handling.hpp.
Referenced by toNativeArray().
void opcua::detail::resizeArray | ( | T *& | array, |
size_t & | size, | ||
size_t | newSize, | ||
const UA_DataType & | type ) |
Definition at line 145 of file types_handling.hpp.
|
nodiscardconstexprnoexcept |
Definition at line 54 of file exception.hpp.
Referenced by opcua::StatusCode::isGood().
|
nodiscardconstexprnoexcept |
Definition at line 58 of file exception.hpp.
Referenced by opcua::StatusCode::isUncertain().
|
nodiscardconstexprnoexcept |
Definition at line 62 of file exception.hpp.
Referenced by opcua::StatusCode::isBad(), and opcua::throwIfBad().
|
inlinenodiscardnoexcept |
Definition at line 67 of file exception.hpp.
Referenced by tryInvoke().
|
noexcept |
|
noexcept |
|
inlineconstexpr |
Definition at line 27 of file client_context.hpp.
|
constexpr |
Definition at line 18 of file types_handling.hpp.
Referenced by clear(), copy(), and copyArray().
|
constexpr |
Definition at line 45 of file typeconverter.hpp.
|
constexpr |
Definition at line 41 of file typeregistry.hpp.
Referenced by opcua::getDataType(), opcua::detail::VariantHandler< VariantPolicy::ReferenceIfPossible >::setArray(), opcua::Variant::setArrayCopy(), opcua::detail::VariantHandler< VariantPolicy::ReferenceIfPossible >::setScalar(), and opcua::Variant::setScalarCopy().
|
constexpr |
Definition at line 126 of file typewrapper.hpp.
|
constexpr |
Definition at line 103 of file wrapper.hpp.
Referenced by opcua::services::detail::getResponseHeader(), opcua::services::detail::getSingleResultRef(), and toNativeArray().