Fesapi 2.9.0.1
This project provides C++ classes which allow an easy access in import and export to the Energistics standards.
Loading...
Searching...
No Matches
Activity.h
1/*-----------------------------------------------------------------------
2Licensed to the Apache Software Foundation (ASF) under one
3or more contributor license agreements. See the NOTICE file
4distributed with this work for additional information
5regarding copyright ownership. The ASF licenses this file
6to you under the Apache License, Version 2.0 (the
7"License"; you may not use this file except in compliance
8with the License. You may obtain a copy of the License at
9
10 http://www.apache.org/licenses/LICENSE-2.0
11
12Unless required by applicable law or agreed to in writing,
13software distributed under the License is distributed on an
14"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15KIND, either express or implied. See the License for the
16specific language governing permissions and limitations
17under the License.
18-----------------------------------------------------------------------*/
19#pragma once
20
21#include "../eml2/Activity.h"
22
23namespace EML2_3_NS
24{
26 class Activity final : public EML2_NS::Activity
27 {
28 protected:
30 Activity() : EML2_NS::Activity() {}
31
33 void loadTargetRelationships() final;
34
35 public:
36
44 DLL_IMPORT_OR_EXPORT Activity(gsoap_resqml2_0_1::eml20__DataObjectReference* partialObject) : EML2_NS::Activity(partialObject) {}
45
56 Activity(EML2_NS::ActivityTemplate* activityTemplate, const std::string & guid, const std::string & title);
57
63 Activity(gsoap_eml2_3::_eml23__Activity* fromGsoap) : EML2_NS::Activity(fromGsoap) {}
64
66 ~Activity() = default;
67
76 DLL_IMPORT_OR_EXPORT void pushBackParameter(const std::string& title,
77 double value, gsoap_resqml2_0_1::resqml20__ResqmlUom uom = gsoap_resqml2_0_1::resqml20__ResqmlUom::Euc);
78
86 DLL_IMPORT_OR_EXPORT void pushBackParameter(const std::string& title,
87 const std::string & value);
88
96 DLL_IMPORT_OR_EXPORT void pushBackParameter(const std::string& title,
97 int64_t value);
98
106 DLL_IMPORT_OR_EXPORT void pushBackParameter(const std::string& title,
107 AbstractObject* resqmlObject);
108
114 DLL_IMPORT_OR_EXPORT uint64_t getParameterCount() const;
115
123 DLL_IMPORT_OR_EXPORT uint64_t getParameterCount(const std::string & paramTitle) const;
124
132 DLL_IMPORT_OR_EXPORT const std::string & getParameterTitle(unsigned int index) const;
133
141 DLL_IMPORT_OR_EXPORT std::vector<unsigned int> getParameterIndexOfTitle(const std::string & paramTitle) const;
142
150 DLL_IMPORT_OR_EXPORT bool isAFloatingPointQuantityParameter(const std::string & paramTitle) const;
151
159 DLL_IMPORT_OR_EXPORT bool isAFloatingPointQuantityParameter(unsigned int index) const;
160
168 DLL_IMPORT_OR_EXPORT std::vector<double> getFloatingPointQuantityParameterValue(const std::string & paramTitle) const;
169
177 DLL_IMPORT_OR_EXPORT double getFloatingPointQuantityParameterValue(unsigned int index) const;
178
186 DLL_IMPORT_OR_EXPORT std::vector<gsoap_resqml2_0_1::resqml20__ResqmlUom> getFloatingPointQuantityParameterUom(const std::string & paramTitle) const;
187
195 DLL_IMPORT_OR_EXPORT gsoap_resqml2_0_1::resqml20__ResqmlUom getFloatingPointQuantityParameterUom(unsigned int index) const;
196
204 DLL_IMPORT_OR_EXPORT bool isAnIntegerQuantityParameter(const std::string & paramTitle) const;
205
213 DLL_IMPORT_OR_EXPORT bool isAnIntegerQuantityParameter(unsigned int index) const;
214
222 DLL_IMPORT_OR_EXPORT std::vector<int32_t> getIntegerQuantityParameterValue(const std::string & paramTitle) const;
223
231 DLL_IMPORT_OR_EXPORT int64_t getIntegerQuantityParameterValue(unsigned int index) const;
232
240 DLL_IMPORT_OR_EXPORT bool isAStringParameter(const std::string & paramTitle) const;
241
249 DLL_IMPORT_OR_EXPORT bool isAStringParameter(unsigned int index) const;
250
258 DLL_IMPORT_OR_EXPORT std::vector<std::string> getStringParameterValue(const std::string & paramTitle) const;
259
267 DLL_IMPORT_OR_EXPORT const std::string & getStringParameterValue(unsigned int index) const;
268
276 DLL_IMPORT_OR_EXPORT bool isAResqmlObjectParameter(const std::string & paramTitle) const;
277
285 DLL_IMPORT_OR_EXPORT bool isAResqmlObjectParameter(unsigned int index) const;
286
294 DLL_IMPORT_OR_EXPORT std::vector<AbstractObject*> getResqmlObjectParameterValue(const std::string & paramTitle) const;
295
303 DLL_IMPORT_OR_EXPORT AbstractObject* getResqmlObjectParameterValue(unsigned int index) const;
304
310 DLL_IMPORT_OR_EXPORT void setActivityTemplate(EML2_NS::ActivityTemplate* activityTemplate);
311
317 COMMON_NS::DataObjectReference getActivityTemplateDor() const;
318
322 DLL_IMPORT_OR_EXPORT static constexpr char const* XML_NS = "eml23";
323
327 DLL_IMPORT_OR_EXPORT std::string getXmlNamespace() const final { return XML_NS; }
328
329 private:
330
338 std::vector<gsoap_eml2_3::eml23__AbstractActivityParameter*> getParameterFromTitle(const std::string & paramTitle) const;
339 };
340}
Definition Activity.h:27
bool isAFloatingPointQuantityParameter(const std::string &paramTitle) const
void pushBackParameter(const std::string &title, double value, gsoap_resqml2_0_1::resqml20__ResqmlUom uom=gsoap_resqml2_0_1::resqml20__ResqmlUom::Euc)
std::string getXmlNamespace() const final
Definition Activity.h:327
Activity(gsoap_resqml2_0_1::eml20__DataObjectReference *partialObject)
Definition Activity.h:44
gsoap_resqml2_0_1::resqml20__ResqmlUom getFloatingPointQuantityParameterUom(unsigned int index) const
bool isAStringParameter(unsigned int index) const
Activity(eml2 ::ActivityTemplate *activityTemplate, const std::string &guid, const std::string &title)
Creates an instance of this class in a gsoap context.
const std::string & getParameterTitle(unsigned int index) const
Activity(gsoap_eml2_3::_eml23__Activity *fromGsoap)
Definition Activity.h:63
std::vector< double > getFloatingPointQuantityParameterValue(const std::string &paramTitle) const
std::vector< std::string > getStringParameterValue(const std::string &paramTitle) const
uint64_t getParameterCount(const std::string &paramTitle) const
std::vector< AbstractObject * > getResqmlObjectParameterValue(const std::string &paramTitle) const
bool isAResqmlObjectParameter(unsigned int index) const
common::DataObjectReference getActivityTemplateDor() const
bool isAFloatingPointQuantityParameter(unsigned int index) const
void pushBackParameter(const std::string &title, const std::string &value)
std::vector< gsoap_resqml2_0_1::resqml20__ResqmlUom > getFloatingPointQuantityParameterUom(const std::string &paramTitle) const
bool isAnIntegerQuantityParameter(const std::string &paramTitle) const
bool isAResqmlObjectParameter(const std::string &paramTitle) const
bool isAnIntegerQuantityParameter(unsigned int index) const
uint64_t getParameterCount() const
int64_t getIntegerQuantityParameterValue(unsigned int index) const
std::vector< int32_t > getIntegerQuantityParameterValue(const std::string &paramTitle) const
~Activity()=default
void setActivityTemplate(eml2 ::ActivityTemplate *activityTemplate)
void pushBackParameter(const std::string &title, AbstractObject *resqmlObject)
double getFloatingPointQuantityParameterValue(unsigned int index) const
bool isAStringParameter(const std::string &paramTitle) const
const std::string & getStringParameterValue(unsigned int index) const
std::vector< unsigned int > getParameterIndexOfTitle(const std::string &paramTitle) const
AbstractObject * getResqmlObjectParameterValue(unsigned int index) const
void pushBackParameter(const std::string &title, int64_t value)