PLCnext API Documentation 23.6.0.37
ITypeInfoProvider.hpp
1
2//
3// Copyright PHOENIX CONTACT Electronics GmbH
4//
6#pragma once
8#include "Arp/System/Core/IEnumerator.hxx"
9#include "Arp/Plc/Commons/Meta/TypeInfo.hpp"
10#include "Arp/Plc/Commons/Meta/ChildInfo.hpp"
11#include "Arp/Plc/Commons/Meta/ChildTypeInfo.hpp"
12#include "Arp/Plc/Commons/Meta/TypeIdentifier.hpp"
13
14namespace Arp { namespace Plc { namespace Commons { namespace Meta
15{
16
17using namespace Arp;
18
25{
26public: // usings
28 using Ptr = std::shared_ptr<ITypeInfoProvider>;
29
30protected: // construction/destruction
32 ITypeInfoProvider(void) = default;
34 virtual ~ITypeInfoProvider(void) = default;
35
36public: // abstract operations
40
45
49 virtual TypeInfo GetTypeInfo(const TypeIdentifier& typeId) = 0;
50
56 virtual ChildInfo GetChildInfo(const TypeIdentifier& type, const String& childName) = 0;
57
62 virtual ChildTypeInfo GetChildTypeInfo(const TypeIdentifier& type, const String& childName) = 0;
63
64private: // deleted methods (for non-copyable classes)
65 ITypeInfoProvider(const ITypeInfoProvider& arg) = delete;
66 ITypeInfoProvider& operator=(const ITypeInfoProvider& arg) = delete;
67};
68
69}}}} // end of namespace Arp::Plc::Commons::Meta
Declares the interface of the enumerator pattern, which is leaned on .NET enumerator idiom.
Definition: IEnumerator.hxx:48
Provides detailed type information of a child within TypeBrowser interface.
Definition: ChildTypeInfo.hpp:27
Interface to type information of a library
Definition: ITypeInfoProvider.hpp:25
virtual IEnumerator< ChildTypeInfo >::Ptr GetChilds(const TypeIdentifier &type)=0
Gets a IEnumerator over all ChildTypeInfos of the type
virtual IEnumerator< TypeInfo >::Ptr GetTypes(void)=0
Gets a IEnumerator over all TypeInfos of this library
std::shared_ptr< ITypeInfoProvider > Ptr
std::shared_ptr to ITypeInfoProvider
Definition: ITypeInfoProvider.hpp:28
virtual ChildInfo GetChildInfo(const TypeIdentifier &type, const String &childName)=0
Gets the ChildInfo of a type's child
virtual TypeInfo GetTypeInfo(const TypeIdentifier &typeId)=0
Gets the TypeInfo of a type
ITypeInfoProvider(void)=default
Constructs an ITypeInfoProvider instance.
virtual ~ITypeInfoProvider(void)=default
Destructs this instance and frees all resources.
virtual ChildTypeInfo GetChildTypeInfo(const TypeIdentifier &type, const String &childName)=0
Gets the ChildTypeInfo of a type's child
Identifies a type descriptions
Definition: TypeIdentifier.hpp:24
Provides detailed type information within TypeBrowser interface.
Definition: TypeInfo.hpp:28
Root namespace for the PLCnext API