Constantin Ziesche | 02817f1 | 2020-08-04 21:40:43 +0200 | [diff] [blame^] | 1 | #ifndef BASYX_MAP_V2_SDK_CONCEPTDESCRIPTION_H |
| 2 | #define BASYX_MAP_V2_SDK_CONCEPTDESCRIPTION_H |
| 3 | |
| 4 | #include <BaSyx/vab/ElementMap.h> |
| 5 | #include <BaSyx/submodel/api_v2/parts/IConceptDescription.h> |
| 6 | #include <BaSyx/submodel/api_v2/dataspecification/IDataSpecification.h> |
| 7 | #include <BaSyx/submodel/map_v2/qualifier/Identifiable.h> |
| 8 | #include <BaSyx/submodel/map_v2/common/ElementContainer.h> |
| 9 | #include <BaSyx/submodel/map_v2/qualifier/HasDataSpecification.h> |
| 10 | #include <BaSyx/submodel/map_v2/dataspecification/DataSpecification.h> |
| 11 | #include <BaSyx/submodel/map_v2/reference/Reference.h> |
| 12 | |
| 13 | |
| 14 | namespace basyx { |
| 15 | namespace submodel { |
| 16 | namespace map { |
| 17 | |
| 18 | struct ConceptDescriptionPath |
| 19 | { |
| 20 | static constexpr char ModelType[] = "ConceptDescription"; |
| 21 | static constexpr char IsCaseOf[] = "isCaseOf"; |
| 22 | static constexpr char EmbeddedDataSpecifications[] = "embeddedDataSpecifications"; |
| 23 | }; |
| 24 | |
| 25 | class ConceptDescription |
| 26 | : public api::IConceptDescription |
| 27 | , public virtual Identifiable |
| 28 | , public virtual HasDataSpecification |
| 29 | { |
| 30 | private: |
| 31 | std::vector<std::unique_ptr<api::IReference>> is_case_of_refs; |
| 32 | ElementContainer<api::IDataSpecification> embedded_data_specs; |
| 33 | |
| 34 | public: |
| 35 | ConceptDescription(const std::string & idShort, const simple::Identifier & identifier); |
| 36 | |
| 37 | const std::vector<std::unique_ptr<api::IReference>> & getIsCaseOf() const override; |
| 38 | const api::IElementContainer<api::IDataSpecification> & getEmbeddedDataSpecification() const override; |
| 39 | |
| 40 | //not inherited |
| 41 | void addIsCaseOf(std::unique_ptr<Reference> reference); |
| 42 | void addEmbeddedDataSpecification(std::unique_ptr<DataSpecification> data_specification); |
| 43 | }; |
| 44 | |
| 45 | } |
| 46 | } |
| 47 | } |
| 48 | #endif //BASYX_MAP_V2_SDK_CONCEPTDESCRIPTION_H |