PLCnext API Documentation  22.9.0.33
Public Types | Public Member Functions | Public Attributes | List of all members
Arp::System::Rsc::Services::RscImplReadEnumerator< T > Class Template Reference

Implements IRscReadEnumeratorfor the service implementations. This should only be used in the implementation. The read callbacks have to be implemented and set by the service. More...

#include <RscImplReadEnumerator.hxx>

Inheritance diagram for Arp::System::Rsc::Services::RscImplReadEnumerator< T >:
Inheritance graph

Public Types

typedef std::function< size_t()> BeginFunction
 
typedef std::function< bool(T &)> NextFunction
 
typedef std::function< bool(RscArrayReader &)> NextArrayFunction
 
typedef std::function< void()> EndFunction
 
- Public Types inherited from Arp::System::Rsc::Services::IRscReadEnumerator< T >
typedef std::shared_ptr< IRscReadEnumeratorPtr
 

Public Member Functions

 RscImplReadEnumerator (void)=default
 Constructs an RscImplReadEnumerator instance. More...
 
 RscImplReadEnumerator (const RscImplReadEnumerator &arg)=default
 Copy constructor. More...
 
RscImplReadEnumeratoroperator= (const RscImplReadEnumerator &arg)=default
 Assignment operator. More...
 
 ~RscImplReadEnumerator (void)=default
 Destructs this instance and frees all resources. More...
 
size_t BeginRead (void) override
 Begins the operation to read the enumerator. More...
 
bool ReadNext (T &) override
 Reads the next enumerator element. More...
 
bool ReadNext (RscArrayReader &current) override
 Reads the next array enumerator element. Use this method only, if element contains object with an array. More...
 
void EndRead (void) override
 Ends the operation to read the enumerator. All enumerator elements had to be already been read. More...
 

Public Attributes

BeginFunction Begin
 Read callback to BeginRead implementation of service method. More...
 
NextFunction Next
 Write callback to ReadNext implementation of service method. More...
 
NextArrayFunction NextArray
 Write callback to ReadNext implementation for array elements of service method. More...
 
EndFunction End
 Write callback to EndRead implementation of service method. More...
 

Additional Inherited Members

- Static Public Attributes inherited from Arp::System::Rsc::Services::IRscReadEnumerator< T >
static constexpr size_t UndefinedArrayLength = std::numeric_limits<size_t>::max()
 
- Protected Member Functions inherited from Arp::System::Rsc::Services::IRscReadEnumerator< T >
 IRscReadEnumerator (void)=default
 Constructs an IRscArrayWriteEnumerator instance. More...
 
virtual ~IRscReadEnumerator (void)=default
 Destructs this instance and frees all resources. More...
 
 IRscReadEnumerator (const IRscReadEnumerator &arg)=default
 
IRscReadEnumeratoroperator= (const IRscReadEnumerator &arg)=default
 

Detailed Description

template<class T>
class Arp::System::Rsc::Services::RscImplReadEnumerator< T >

Implements IRscReadEnumeratorfor the service implementations. This should only be used in the implementation. The read callbacks have to be implemented and set by the service.

Constructor & Destructor Documentation

◆ RscImplReadEnumerator() [1/2]

template<class T >
Arp::System::Rsc::Services::RscImplReadEnumerator< T >::RscImplReadEnumerator ( void  )
default

Constructs an RscImplReadEnumerator instance.

◆ RscImplReadEnumerator() [2/2]

Copy constructor.

◆ ~RscImplReadEnumerator()

template<class T >
Arp::System::Rsc::Services::RscImplReadEnumerator< T >::~RscImplReadEnumerator ( void  )
default

Destructs this instance and frees all resources.

Member Function Documentation

◆ BeginRead()

template<class T >
size_t Arp::System::Rsc::Services::RscImplReadEnumerator< T >::BeginRead ( void  )
inlineoverridevirtual

Begins the operation to read the enumerator.

Returns
Number of elements for array enumerators. UndefinedArrayLength for regular enumerators

Implements Arp::System::Rsc::Services::IRscReadEnumerator< T >.

◆ EndRead()

template<class T >
void Arp::System::Rsc::Services::RscImplReadEnumerator< T >::EndRead ( void  )
inlineoverridevirtual

Ends the operation to read the enumerator. All enumerator elements had to be already been read.

Implements Arp::System::Rsc::Services::IRscReadEnumerator< T >.

◆ operator=()

template<class T >
RscImplReadEnumerator& Arp::System::Rsc::Services::RscImplReadEnumerator< T >::operator= ( const RscImplReadEnumerator< T > &  arg)
default

Assignment operator.

◆ ReadNext() [1/2]

template<class T >
bool Arp::System::Rsc::Services::RscImplReadEnumerator< T >::ReadNext ( RscArrayReader current)
inlineoverridevirtual

Reads the next array enumerator element. Use this method only, if element contains object with an array.

Parameters
currentReference to RscArrayReader. The given RscArrayReader will be configured by this method.
Returns
true if valid element was read

Implements Arp::System::Rsc::Services::IRscReadEnumerator< T >.

◆ ReadNext() [2/2]

template<class T >
bool Arp::System::Rsc::Services::RscImplReadEnumerator< T >::ReadNext ( T &  current)
inlineoverridevirtual

Reads the next enumerator element.

Parameters
currentPlace to store next element
Returns
true if valid element was read

Implements Arp::System::Rsc::Services::IRscReadEnumerator< T >.

Member Data Documentation

◆ Begin

template<class T >
BeginFunction Arp::System::Rsc::Services::RscImplReadEnumerator< T >::Begin

Read callback to BeginRead implementation of service method.

◆ End

template<class T >
EndFunction Arp::System::Rsc::Services::RscImplReadEnumerator< T >::End

Write callback to EndRead implementation of service method.

◆ Next

template<class T >
NextFunction Arp::System::Rsc::Services::RscImplReadEnumerator< T >::Next

Write callback to ReadNext implementation of service method.

◆ NextArray

template<class T >
NextArrayFunction Arp::System::Rsc::Services::RscImplReadEnumerator< T >::NextArray

Write callback to ReadNext implementation for array elements of service method.


The documentation for this class was generated from the following file: