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

Loading...
Searching...
No Matches
BusConnector.h
Go to the documentation of this file.
1#ifndef BUSCONNECTOR_H
2#define BUSCONNECTOR_H
3
4
5#include "ComRef.h"
6#include "OMSimulator/Types.h"
7#include "Connector.h"
8#include "ssd/ConnectorGeometry.h"
9
10#include <string>
11#include <vector>
12
13#include <pugixml.hpp>
14
15 namespace oms
16{
20 class BusConnector : protected oms_busconnector_t
21 {
22 public:
23 BusConnector(const oms::ComRef& name);
24 ~BusConnector();
25
26 oms_status_enu_t exportToSSD(pugi::xml_node& root) const;
27
28 // methods to copy the object
29 BusConnector(const BusConnector& rhs);
30 BusConnector& operator=(const BusConnector& rhs);
31
32 void setName(const oms::ComRef& name);
33 void setGeometry(const oms::ssd::ConnectorGeometry* newGeometry);
34
35 const oms::ComRef getName() const {return oms::ComRef(name);}
36 const oms::ssd::ConnectorGeometry* getGeometry() const {return reinterpret_cast<oms::ssd::ConnectorGeometry*>(geometry);}
37
38 oms_status_enu_t addConnector(const oms::ComRef& cref);
39 oms_status_enu_t deleteConnector(const oms::ComRef& cref);
40 std::vector<oms::ComRef> getConnectors() const {return conrefs;}
41
42 void updateConnectors();
43
44 private:
45 std::vector<oms::ComRef> conrefs;
46 };
47}
48
49#endif // BUSCONNECTOR_H
ComRef.h
ConnectorGeometry.h
Connector.h
oms::BusConnector
BusConnector.
Definition BusConnector.h:21
oms::BusConnector::getGeometry
const oms::ssd::ConnectorGeometry * getGeometry() const
Definition BusConnector.h:36
oms::BusConnector::getConnectors
std::vector< oms::ComRef > getConnectors() const
Definition BusConnector.h:40
oms::BusConnector::setGeometry
void setGeometry(const oms::ssd::ConnectorGeometry *newGeometry)
Definition BusConnector.cpp:83
oms::BusConnector::updateConnectors
void updateConnectors()
Definition BusConnector.cpp:114
oms::BusConnector::operator=
BusConnector & operator=(const BusConnector &rhs)
Definition BusConnector.cpp:57
oms::BusConnector::addConnector
oms_status_enu_t addConnector(const oms::ComRef &cref)
Definition BusConnector.cpp:95
oms::BusConnector::getName
const oms::ComRef getName() const
Definition BusConnector.h:35
oms::BusConnector::exportToSSD
oms_status_enu_t exportToSSD(pugi::xml_node &root) const
Definition BusConnector.cpp:28
oms::BusConnector::~BusConnector
~BusConnector()
Definition BusConnector.cpp:17
oms::BusConnector::setName
void setName(const oms::ComRef &name)
Definition BusConnector.cpp:73
oms::BusConnector::deleteConnector
oms_status_enu_t deleteConnector(const oms::ComRef &cref)
Definition BusConnector.cpp:102
oms::BusConnector::conrefs
std::vector< oms::ComRef > conrefs
Definition BusConnector.h:45
oms::ComRef
ComRef - component reference.
Definition ComRef.h:47
oms::ssd::ConnectorGeometry
Definition ConnectorGeometry.h:46
oms
Definition AlgLoop.h:45