PLCnext API Documentation 25.0.2.69
|
Implements IRscReadEnumerator to be used from within service implementations. More...
#include <RscImplReadEnumerator.hxx>
Public Types | |
using | BeginFunction = std::function< size_t()> |
The prototype of the Begin function. | |
using | NextFunction = std::function< bool(T &)> |
The prototype of the Next function. | |
using | NextArrayFunction = std::function< bool(RscArrayReader &)> |
The prototype of the NextArray function. | |
using | EndFunction = std::function< void()> |
The prototype of the End function. | |
![]() | |
using | Ptr = std::shared_ptr< IRscReadEnumerator > |
The pointer type of this type. | |
Public Member Functions | |
RscImplReadEnumerator (void) | |
Constructs an RscImplReadEnumerator instance. More... | |
size_t | BeginRead (void) override |
This operation is called at the begin of reading the enumeration. More... | |
bool | ReadNext (T &) override |
Reads the next element of the enumeration. More... | |
bool | ReadNext (RscArrayReader ¤t) override |
Reads the next array element of the enumeration. More... | |
void | EndRead (void) override |
This operation is called at the end of reading the enumeration to perform any cleanup code or similar. More... | |
![]() | |
IRscReadEnumerator (void)=default | |
The default constructor. | |
IRscReadEnumerator (const IRscReadEnumerator &arg)=delete | |
The deleted copy constructor. More... | |
IRscReadEnumerator (IRscReadEnumerator &&arg) noexcept=default | |
The default move constructor. More... | |
IRscReadEnumerator & | operator= (const IRscReadEnumerator &arg)=delete |
The deleted assignment operator. More... | |
IRscReadEnumerator & | operator= (IRscReadEnumerator &&arg) noexcept=default |
The default move-assignment operator. More... | |
virtual | ~IRscReadEnumerator (void)=default |
Destructs this instance and frees all resources. | |
virtual size_t | BeginRead (void)=0 |
Begins to read the enumeration values. More... | |
virtual bool | ReadNext (T ¤t)=0 |
Reads the next enumeration value. More... | |
virtual bool | ReadNext (RscArrayReader ¤t)=0 |
Reads the next array object. Use this method only, if the current enumerated value contains an array object. More... | |
virtual void | EndRead (void)=0 |
Call this operation when all enumeration values has been read, to perform checks and cleanup. More... | |
Public Attributes | |
BeginFunction | Begin |
Delegate to BeginRead method of service implementation. | |
NextFunction | Next |
Delegate to ReadNext method of service implementation. | |
NextArrayFunction | NextArray |
Delegate to ReadNext method for array elements of service implementation. | |
EndFunction | End |
Delegate to EndRead method of service implementation. | |
Additional Inherited Members | |
![]() | |
static constexpr size_t | UndefinedArrayLength = std::numeric_limits<size_t>::max() |
This constant is used to determine that an enumeration is not an array enumeration and hence has an unknown length. | |
Implements IRscReadEnumerator to be used from within service implementations.
This class should only be used in service implementations. The read callbacks (lambdas) have to be implemented and set by the service.
T | The enumerated type. |
|
inlinedefault |
Constructs an RscImplReadEnumerator instance.
T | The enumerated type. |
|
inlineoverridevirtual |
This operation is called at the begin of reading the enumeration.
T | The enumerated type. |
Implements Arp::Base::Rsc::Commons::IRscReadEnumerator< T >.
|
inlineoverridevirtual |
This operation is called at the end of reading the enumeration to perform any cleanup code or similar.
T | The enumerated type. |
Implements Arp::Base::Rsc::Commons::IRscReadEnumerator< T >.
|
inlineoverridevirtual |
Reads the next array element of the enumeration.
current | The array reader to read the current array element. |
true
if the next array element could be read, otherwise false
to indicate the end of the enumeration. T | The enumerated type. |
Implements Arp::Base::Rsc::Commons::IRscReadEnumerator< T >.
|
inlineoverridevirtual |
Reads the next element of the enumeration.
true
if the next element could be read, otherwise false
to indicate the end of the enumeration. current | The read element. |
T | The enumerated type. |
Implements Arp::Base::Rsc::Commons::IRscReadEnumerator< T >.