OMSimulatorLib The OMSimulator project is a FMI-based co-simulation environment.

Loading...
Searching...
No Matches
ConnectionGeometry.h
Go to the documentation of this file.
1/*
2 * This file is part of OpenModelica.
3 *
4 * Copyright (c) 1998-2026, Open Source Modelica Consortium (OSMC),
5 * c/o Linköpings universitet, Department of Computer and Information Science,
6 * SE-58183 Linköping, Sweden.
7 *
8 * All rights reserved.
9 *
10 * THIS PROGRAM IS PROVIDED UNDER THE TERMS OF AGPL VERSION 3 LICENSE OR
11 * THIS OSMC PUBLIC LICENSE (OSMC-PL) VERSION 1.8.
12 * ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS PROGRAM CONSTITUTES
13 * RECIPIENT'S ACCEPTANCE OF THE OSMC PUBLIC LICENSE OR THE GNU AGPL
14 * VERSION 3, ACCORDING TO RECIPIENTS CHOICE.
15 *
16 * The OpenModelica software and the OSMC (Open Source Modelica Consortium)
17 * Public License (OSMC-PL) are obtained from OSMC, either from the above
18 * address, from the URLs:
19 * http://www.openmodelica.org or
20 * https://github.com/OpenModelica/ or
21 * http://www.ida.liu.se/projects/OpenModelica,
22 * and in the OpenModelica distribution.
23 *
24 * GNU AGPL version 3 is obtained from:
25 * https://www.gnu.org/licenses/licenses.html#GPL
26 *
27 * This program is distributed WITHOUT ANY WARRANTY; without
28 * even the implied warranty of MERCHANTABILITY or FITNESS
29 * FOR A PARTICULAR PURPOSE, EXCEPT AS EXPRESSLY SET FORTH
30 * IN THE BY RECIPIENT SELECTED SUBSIDIARY LICENSE CONDITIONS OF OSMC-PL.
31 *
32 * See the full OSMC Public License conditions for more details.
33 *
34 */
35
36#ifndef _SSD_CONNECTION_GEOMETRY_H_
37#define _SSD_CONNECTION_GEOMETRY_H_
38
39#include "OMSimulator/Types.h"
40
41#include <pugixml.hpp>
42
43#include <string>
44
45 namespace oms
46{
47 namespace ssd
48 {
49 class ConnectionGeometry : protected ssd_connection_geometry_t
50 {
51 public:
52 ConnectionGeometry();
53 ConnectionGeometry(const ConnectionGeometry& rhs, bool inverse=false);
54 ~ConnectionGeometry();
55
56 ConnectionGeometry& operator=(ConnectionGeometry const& rhs);
57
58 void setPoints(unsigned int n, double* pointsX, double* pointsY);
59
60 unsigned int getLength() const {return this->n;}
61 const double* getPointsX() const {return this->pointsX;}
62 const double* getPointsY() const {return this->pointsY;}
63
64 oms_status_enu_t exportToSSD(pugi::xml_node& root) const;
65 oms_status_enu_t importFromSSD(const pugi::xml_node& node);
66 };
67 }
68}
69
70#endif
oms::ssd::ConnectionGeometry
Definition ConnectionGeometry.h:50
oms::ssd::ConnectionGeometry::ConnectionGeometry
ConnectionGeometry()
Definition ConnectionGeometry.cpp:46
oms::ssd::ConnectionGeometry::getPointsX
const double * getPointsX() const
Definition ConnectionGeometry.h:61
oms::ssd::ConnectionGeometry::operator=
ConnectionGeometry & operator=(ConnectionGeometry const &rhs)
Definition ConnectionGeometry.cpp:91
oms::ssd::ConnectionGeometry::exportToSSD
oms_status_enu_t exportToSSD(pugi::xml_node &root) const
Definition ConnectionGeometry.cpp:147
oms::ssd::ConnectionGeometry::~ConnectionGeometry
~ConnectionGeometry()
Definition ConnectionGeometry.cpp:80
oms::ssd::ConnectionGeometry::getLength
unsigned int getLength() const
Definition ConnectionGeometry.h:60
oms::ssd::ConnectionGeometry::getPointsY
const double * getPointsY() const
Definition ConnectionGeometry.h:62
oms::ssd::ConnectionGeometry::importFromSSD
oms_status_enu_t importFromSSD(const pugi::xml_node &node)
Definition ConnectionGeometry.cpp:173
oms::ssd::ConnectionGeometry::setPoints
void setPoints(unsigned int n, double *pointsX, double *pointsY)
Definition ConnectionGeometry.cpp:123
oms
Definition AlgLoop.h:52