PLCnext API Documentation 23.6.0.37
Public Member Functions | List of all members
Arp::System::Rsc::Services::RscComponentServiceImplBase Class Reference

Base class for Rsc component service implementations. Contains reference to associated component. More...

#include <RscComponentServiceImplBase.hpp>

Public Member Functions

 RscComponentServiceImplBase (IComponent &component)
 Constructs an RscComponentServiceImplBase instance.
 
 ~RscComponentServiceImplBase (void)=default
 Destructs this instance and frees all resources.
 
template<class T >
T & GetComponent (void)
 Gets a reference to the associated service. Throws if T doesn't match type of component. More...
 
IComponentGetComponent (void)
 Gets a reference to associated service. More...
 

Detailed Description

Base class for Rsc component service implementations. Contains reference to associated component.

Member Function Documentation

◆ GetComponent() [1/2]

template<class T >
T & Arp::System::Rsc::Services::RscComponentServiceImplBase::GetComponent ( void  )
inline

Gets a reference to the associated service. Throws if T doesn't match type of component.

Returns
Reference to component
Template Parameters
TType of component
Exceptions
InvalidCastExceptionThrows if T doesn't match type of component.

◆ GetComponent() [2/2]

IComponent & Arp::System::Rsc::Services::RscComponentServiceImplBase::GetComponent ( void  )
inline

Gets a reference to associated service.

Returns
Reference to component via interface IComponent

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