blob: 3feff855b41a959bd8c514dbbb0287619d99f7a6 [file] [log] [blame]
Thomas Psota7e562b62020-04-30 15:11:32 +02001#include <BaSyx/submodel/simple/dataspecification/DataSpecification.h>
2
3namespace basyx {
4namespace submodel {
5namespace simple {
6
7using namespace basyx::submodel::api;
8
9DataSpecification::DataSpecification(const std::string & idShort, const Identifier & identifier)
10 : ident(idShort, identifier)
11 , content(nullptr)
Constantin Ziesche02817f12020-08-04 21:40:43 +020012{}
Thomas Psota7e562b62020-04-30 15:11:32 +020013
14void DataSpecification::setContent(std::unique_ptr<IDataSpecificationContent> content)
15{
16 this->content = std::move(content);
17};
18
19const std::string & DataSpecification::getIdShort() const
20{
21 return this->ident.getIdShort();
22}
23
24const std::string * const DataSpecification::getCategory() const
25{
26 return this->ident.getCategory();
27}
28
29simple::LangStringSet & DataSpecification::getDescription()
30{
31 return this->ident.getDescription();
32}
33
34const simple::LangStringSet & DataSpecification::getDescription() const
35{
36 return this->ident.getDescription();
37}
38
39const IReferable * const DataSpecification::getParent() const
40{
41 return this->ident.getParent();
42}
43
44const AdministrativeInformation & DataSpecification::getAdministrativeInformation() const
45{
46 return this->ident.getAdministrativeInformation();
47}
48
49AdministrativeInformation & DataSpecification::getAdministrativeInformation()
50{
51 return this->ident.getAdministrativeInformation();
52}
53
54Identifier DataSpecification::getIdentification() const
55{
56 return this->ident.getIdentification();
57}
58
59bool DataSpecification::hasAdministrativeInformation() const
60{
61 return this->ident.hasAdministrativeInformation();
62}
63
64IDataSpecificationContent & DataSpecification::getContent()
65{
66 return *this->content;
67}
68
Constantin Ziesche02817f12020-08-04 21:40:43 +020069void DataSpecification::setCategory(const std::string &category)
70{
71 this->ident.setCategory(category);
72}
73
Thomas Psota7e562b62020-04-30 15:11:32 +020074
75}
76}
77}