My Project
AbstractProperty.h
1 /*-----------------------------------------------------------------------
2 Copyright F2I-CONSULTING, (2014-2017)
3 
4 philippe.verney@f2i-consulting.com
5 
6 This software is a computer program whose purpose is to access to data formatted using Energistics standards.
7 
8 This software is governed by the CeCILL-B license under French law and
9 abiding by the rules of distribution of free software. You can use,
10 modify and/ or redistribute the software under the terms of the CeCILL-B
11 license as circulated by CEA, CNRS and INRIA at the following URL
12 "http://www.cecill.info".
13 
14 As a counterpart to the access to the source code and rights to copy,
15 modify and redistribute granted by the license, users are provided only
16 with a limited warranty and the software's author, the holder of the
17 economic rights, and the successive licensors have only limited
18 liability.
19 
20 In this respect, the user's attention is drawn to the risks associated
21 with loading, using, modifying and/or developing or reproducing the
22 software by the user in light of its specific status of free software,
23 that may mean that it is complicated to manipulate, and that also
24 therefore means that it is reserved for developers and experienced
25 professionals having in-depth computer knowledge. Users are therefore
26 encouraged to load and test the software's suitability as regards their
27 requirements in conditions enabling the security of their systems and/or
28 data to be ensured and, more generally, to use and operate it in the
29 same conditions as regards security.
30 
31 The fact that you are presently reading this means that you have had
32 knowledge of the CeCILL-B license and that you accept its terms.
33 
34 -----------------------------------------------------------------------*/
35 #pragma once
36 
37 #include "common/AbstractObject.h"
38 
39 namespace resqml2
40 {
41  class DLL_IMPORT_OR_EXPORT AbstractProperty: public common::AbstractObject
42  {
43  public:
44 
48  AbstractProperty(gsoap_resqml2_0_1::eml20__DataObjectReference* partialObject) : common::AbstractObject(partialObject) {}
49 
54  AbstractProperty(): local3dCrs(nullptr) {}
55 
59  AbstractProperty(gsoap_resqml2_0_1::resqml2__AbstractProperty* fromGsoap) : common::AbstractObject(fromGsoap), local3dCrs(nullptr) {}
60 
64  virtual ~AbstractProperty() {}
65 
69  void setRepresentation(class AbstractRepresentation * rep);
70 
74  gsoap_resqml2_0_1::eml20__DataObjectReference* getRepresentationDor() const;
75 
79  class AbstractRepresentation* getRepresentation() const;
80 
81  /*
82  * Getter for the uuid of the representation which is described by this property
83  */
84  std::string getRepresentationUuid() const;
85 
86  /*
87  * Getter for the title of the representation which is described by this property
88  */
89  std::string getRepresentationTitle() const;
90 
91  /*
92  * Getter for the content type of the representation which is described by this property
93  */
94  std::string getRepresentationContentType() const;
95 
99  void setTimeSeries(class TimeSeries * ts);
100 
104  TimeSeries* getTimeSeries() const;
105 
109  gsoap_resqml2_0_1::eml20__DataObjectReference* getTimeSeriesDor() const;
110 
111  /*
112  * Getter for the uuid of the time series which is associated to this property.
113  */
114  std::string getTimeSeriesUuid() const;
115 
116  /*
117  * Getter for the uuid of the time series which is associated to this property.
118  */
119  std::string getTimeSeriesTitle() const;
120 
127  void setTimeIndex(const unsigned int & timeIndex, class TimeSeries * ts);
128 
132  void setTimeStep(const unsigned int & timeStep);
133 
138  time_t getTimestamp() const;
139 
143  unsigned int getTimeIndex() const;
144 
148  void setHdfProxy(common::AbstractHdfProxy * proxy);
149 
153  common::AbstractHdfProxy* getHdfProxy() const;
154 
155  /*
156  * Getter for the uuid of the hdf proxy which is used for storing the numerical values of this property.
157  * An empty string is returned if no hd fproxy is used for storing the numerical values.
158  */
159  std::string getHdfProxyUuid() const;
160 
167  unsigned int getElementCountPerValue() const;
168 
172  gsoap_resqml2_0_1::resqml2__IndexableElements getAttachmentKind() const;
173 
177  bool isAssociatedToOneStandardEnergisticsPropertyKind() const;
178 
179  //*********************************************
180  //****** PROP KIND ****************************
181  //*********************************************
182 
186  std::string getPropertyKindDescription() const;
187 
191  std::string getPropertyKindAsString() const;
192 
196  std::string getPropertyKindParentAsString() const;
197 
201  gsoap_resqml2_0_1::resqml2__ResqmlPropertyKind getEnergisticsPropertyKind() const;
202 
206  void setLocalPropertyKind(class PropertyKind* propKind);
207 
211  gsoap_resqml2_0_1::eml20__DataObjectReference* getLocalPropertyKindDor() const;
212 
216  std::string getLocalPropertyKindUuid() const;
217 
221  std::string getLocalPropertyKindTitle() const;
222 
227  class PropertyKind* getLocalPropertyKind() const;
228 
232  virtual bool validatePropertyKindAssociation(class PropertyKind* pk) = 0;
233 
237  virtual bool validatePropertyKindAssociation(const gsoap_resqml2_0_1::resqml2__ResqmlPropertyKind & pk) = 0;
238 
239  protected:
240 
241  void setXmlRepresentation(class AbstractRepresentation * rep);
242  void setXmlTimeSeries(TimeSeries * ts);
243  void setXmlLocalPropertyKind(class PropertyKind* propKind);
244 
245  virtual std::vector<epc::Relationship> getAllEpcRelationships() const;
246  virtual void importRelationshipSetFromEpc(common::EpcDocument * epcDoc);
247 
248  class AbstractLocal3dCrs * local3dCrs;
249  };
250 }
AbstractProperty(gsoap_resqml2_0_1::resqml2__AbstractProperty *fromGsoap)
Definition: AbstractProperty.h:59
AbstractProperty(gsoap_resqml2_0_1::eml20__DataObjectReference *partialObject)
Definition: AbstractProperty.h:48
Definition: AbstractLocal3dCrs.h:40
Definition: PropertyKind.h:40
virtual ~AbstractProperty()
Definition: AbstractProperty.h:64
AbstractProperty()
Definition: AbstractProperty.h:54
Definition: EpcDocument.h:168
Definition: AbstractObject.h:42
Definition: AbstractRepresentation.h:44
Definition: AbstractHdfProxy.h:43
Definition: AbstractProperty.h:41
Definition: TimeSeries.h:40
Definition: EpcDocument.h:62
Definition: AbstractHdfProxy.h:45