open62541pp 0.16.0
C++ wrapper of open62541
Loading...
Searching...
No Matches
opcua::NumericRange Class Reference

#include <types.hpp>

Detailed Description

Numeric range to indicate subsets of (multidimensional) arrays.

They are no official data type in the OPC UA standard and are transmitted only with a string encoding, such as "1:2,0:3,5". The colon separates min/max index and the comma separates dimensions. A single value indicates a range with a single element (min==max).

See also
https://reference.opcfoundation.org/Core/Part4/v105/docs/7.27
Examples
server_datasource.cpp.

Definition at line 1893 of file types.hpp.

Public Member Functions

 NumericRange ()=default
 
 NumericRange (std::string_view encodedRange)
 
 NumericRange (const char *encodedRange)
 
 NumericRange (Span< const NumericRangeDimension > dimensions)
 
 NumericRange (const UA_NumericRange &native)
 
bool empty () const noexcept
 
Span< const NumericRangeDimensiondimensions () const noexcept
 
std::string toString () const
 

Constructor & Destructor Documentation

◆ NumericRange() [1/5]

opcua::NumericRange::NumericRange ( )
default

◆ NumericRange() [2/5]

opcua::NumericRange::NumericRange ( std::string_view encodedRange)
explicit

◆ NumericRange() [3/5]

opcua::NumericRange::NumericRange ( const char * encodedRange)
inlineexplicit

Definition at line 1899 of file types.hpp.

◆ NumericRange() [4/5]

opcua::NumericRange::NumericRange ( Span< const NumericRangeDimension > dimensions)
inlineexplicit

Definition at line 1902 of file types.hpp.

◆ NumericRange() [5/5]

opcua::NumericRange::NumericRange ( const UA_NumericRange & native)
inlineexplicit

Definition at line 1905 of file types.hpp.

Member Function Documentation

◆ empty()

bool opcua::NumericRange::empty ( ) const
inlinenoexcept

Definition at line 1908 of file types.hpp.

◆ dimensions()

Span< const NumericRangeDimension > opcua::NumericRange::dimensions ( ) const
inlinenoexcept

Definition at line 1912 of file types.hpp.

◆ toString()

std::string opcua::NumericRange::toString ( ) const