Commit 04498fee authored by Aaron Bray's avatar Aaron Bray
Browse files

Merge Flow units with appropriate pressure,volume,time based unit

parent 13531579
......@@ -160,10 +160,6 @@ class SEScalarElectricResistance; class ElectricResistanceUnit;
class SEScalarEnergy; class EnergyUnit;
class SEScalarEnergyPerAmount; class EnergyPerAmountUnit;
class SEScalarEnergyPerMass; class EnergyPerMassUnit;
class SEScalarFlowCompliance; class FlowComplianceUnit;
class SEScalarFlowElastance; class FlowElastanceUnit;
class SEScalarFlowInertance; class FlowInertanceUnit;
class SEScalarFlowResistance; class FlowResistanceUnit;
class SEScalarForce; class ForceUnit;
class SEScalar0To1;
class SEScalarFrequency; class FrequencyUnit;
......@@ -192,8 +188,10 @@ class SEScalarPower; class PowerUnit;
class SEScalarPowerPerAreaTemperatureToTheFourth; class PowerPerAreaTemperatureToTheFourthUnit;
class SEScalarPressure; class PressureUnit;
class SEScalarPressurePerVolume; class PressurePerVolumeUnit;
class SEScalarPressureTimePerVolume; class PressureTimePerVolumeUnit;
class SEScalarPressureTimePerVolumeArea; class PressureTimePerVolumeAreaUnit;
class SEScalarPressureTimePerArea; class PressureTimePerAreaUnit;
class SEScalarPressureTimeSquaredPerVolume; class PressureTimeSquaredPerVolumeUnit;
class SEScalarTime; class TimeUnit;
class SEScalarTemperature; class TemperatureUnit;
class SEScalarVolume; class VolumeUnit;
......
......@@ -7,10 +7,10 @@
#include "properties/SEScalarElectricCurrent.h"
#include "properties/SEScalarElectricInductance.h"
#include "properties/SEScalarElectricResistance.h"
#include "properties/SEScalarFlowCompliance.h"
#include "properties/SEScalarVolumePerPressure.h"
#include "properties/SEScalarVolumePerTime.h"
#include "properties/SEScalarFlowInertance.h"
#include "properties/SEScalarFlowResistance.h"
#include "properties/SEScalarPressureTimeSquaredPerVolume.h"
#include "properties/SEScalarPressureTimePerVolume.h"
#include "properties/SEScalarHeatCapacitance.h"
#include "properties/SEScalarPower.h"
#include "properties/SEScalarHeatInductance.h"
......@@ -19,7 +19,7 @@
#define CIRCUIT_PATH_TEMPLATE typename FluxScalar, typename ResistanceScalar, typename CapacitanceScalar, typename InductanceScalar, typename PotentialScalar, typename QuantityScalar
#define CIRCUIT_PATH_TYPES FluxScalar,ResistanceScalar,CapacitanceScalar,InductanceScalar,PotentialScalar,QuantityScalar
#define ELECTRICAL_CIRCUIT_PATH SEScalarElectricCurrent, SEScalarElectricResistance, SEScalarElectricCapacitance, SEScalarElectricInductance, SEScalarElectricPotential, SEScalarElectricCharge
#define FLUID_CIRCUIT_PATH SEScalarVolumePerTime, SEScalarFlowResistance, SEScalarFlowCompliance, SEScalarFlowInertance, SEScalarPressure, SEScalarVolume
#define FLUID_CIRCUIT_PATH SEScalarVolumePerTime, SEScalarPressureTimePerVolume, SEScalarVolumePerPressure, SEScalarPressureTimeSquaredPerVolume, SEScalarPressure, SEScalarVolume
#define THERMAL_CIRCUIT_PATH SEScalarPower, SEScalarHeatResistance, SEScalarHeatCapacitance, SEScalarHeatInductance, SEScalarTemperature, SEScalarEnergy
template<CIRCUIT_PATH_TEMPLATE>
......
......@@ -5,12 +5,12 @@
#include "circuit/fluid/SEFluidCircuitCalculator.h"
SEFluidCircuitCalculator::SEFluidCircuitCalculator(Logger* logger) : SECircuitCalculator<SEFluidCircuit,SEFluidCircuitNode,SEFluidCircuitPath, FlowComplianceUnit, VolumePerTimeUnit, FlowInertanceUnit, PressureUnit, VolumeUnit, FlowResistanceUnit>(
FlowComplianceUnit::m3_Per_Pa,VolumePerTimeUnit::m3_Per_s, FlowInertanceUnit::Pa_s2_Per_m3,PressureUnit::Pa,VolumeUnit::m3,FlowResistanceUnit::Pa_s_Per_m3,logger)
SEFluidCircuitCalculator::SEFluidCircuitCalculator(Logger* logger) : SECircuitCalculator<SEFluidCircuit,SEFluidCircuitNode,SEFluidCircuitPath, VolumePerPressureUnit, VolumePerTimeUnit, PressureTimeSquaredPerVolumeUnit, PressureUnit, VolumeUnit, PressureTimePerVolumeUnit>(
VolumePerPressureUnit::m3_Per_Pa,VolumePerTimeUnit::m3_Per_s, PressureTimeSquaredPerVolumeUnit::Pa_s2_Per_m3,PressureUnit::Pa,VolumeUnit::m3,PressureTimePerVolumeUnit::Pa_s_Per_m3,logger)
{
}
SEFluidCircuitCalculator::SEFluidCircuitCalculator(const FlowComplianceUnit& c, const VolumePerTimeUnit& f, const FlowInertanceUnit& i, const PressureUnit& p, const VolumeUnit& q, const FlowResistanceUnit& r, Logger* logger) : SECircuitCalculator<SEFluidCircuit, SEFluidCircuitNode, SEFluidCircuitPath, FlowComplianceUnit, VolumePerTimeUnit, FlowInertanceUnit, PressureUnit, VolumeUnit, FlowResistanceUnit>(c, f, i, p, q, r, logger)
SEFluidCircuitCalculator::SEFluidCircuitCalculator(const VolumePerPressureUnit& c, const VolumePerTimeUnit& f, const PressureTimeSquaredPerVolumeUnit& i, const PressureUnit& p, const VolumeUnit& q, const PressureTimePerVolumeUnit& r, Logger* logger) : SECircuitCalculator<SEFluidCircuit, SEFluidCircuitNode, SEFluidCircuitPath, VolumePerPressureUnit, VolumePerTimeUnit, PressureTimeSquaredPerVolumeUnit, PressureUnit, VolumeUnit, PressureTimePerVolumeUnit>(c, f, i, p, q, r, logger)
{
}
......
......@@ -6,11 +6,11 @@
#include "circuit/SECircuitCalculator.h"
#include "circuit/fluid/SEFluidCircuit.h"
class CDM_DECL SEFluidCircuitCalculator : public SECircuitCalculator<SEFluidCircuit, SEFluidCircuitNode, SEFluidCircuitPath, FlowComplianceUnit, VolumePerTimeUnit, FlowInertanceUnit, PressureUnit, VolumeUnit, FlowResistanceUnit>
class CDM_DECL SEFluidCircuitCalculator : public SECircuitCalculator<SEFluidCircuit, SEFluidCircuitNode, SEFluidCircuitPath, VolumePerPressureUnit, VolumePerTimeUnit, PressureTimeSquaredPerVolumeUnit, PressureUnit, VolumeUnit, PressureTimePerVolumeUnit>
{
public:
SEFluidCircuitCalculator(Logger* logger);
SEFluidCircuitCalculator(const FlowComplianceUnit&, const VolumePerTimeUnit&, const FlowInertanceUnit&, const PressureUnit&, const VolumeUnit&, const FlowResistanceUnit&, Logger* logger);
SEFluidCircuitCalculator(const VolumePerPressureUnit&, const VolumePerTimeUnit&, const PressureTimeSquaredPerVolumeUnit&, const PressureUnit&, const VolumeUnit&, const PressureTimePerVolumeUnit&, Logger* logger);
virtual ~SEFluidCircuitCalculator();
};
\ No newline at end of file
......@@ -3,15 +3,15 @@
#include "stdafx.h"
#include "circuit/fluid/SEFluidCircuitPath.h"
#include "properties/SEScalarFlowResistance.h"
#include "properties/SEScalarFlowCompliance.h"
#include "properties/SEScalarFlowInertance.h"
#include "properties/SEScalarPressureTimePerVolume.h"
#include "properties/SEScalarVolumePerPressure.h"
#include "properties/SEScalarPressureTimeSquaredPerVolume.h"
#include "properties/SEScalarVolumePerTime.h"
#include "properties/SEScalarPressure.h"
#include "properties/SEScalarVolume.h"
SEFluidCircuitPath::SEFluidCircuitPath(SEFluidCircuitNode& src, SEFluidCircuitNode& tgt, const std::string& name) :
SECircuitPath<SEScalarVolumePerTime, SEScalarFlowResistance, SEScalarFlowCompliance, SEScalarFlowInertance, SEScalarPressure, SEScalarVolume>(src, tgt, name),
SECircuitPath<SEScalarVolumePerTime, SEScalarPressureTimePerVolume, SEScalarVolumePerPressure, SEScalarPressureTimeSquaredPerVolume, SEScalarPressure, SEScalarVolume>(src, tgt, name),
m_FluidSourceNode(src), m_FluidTargetNode(tgt)
{
......@@ -34,11 +34,11 @@ bool SEFluidCircuitPath::HasResistance() const
{
return SECircuitPath::HasResistance();
}
SEScalarFlowResistance& SEFluidCircuitPath::GetResistance()
SEScalarPressureTimePerVolume& SEFluidCircuitPath::GetResistance()
{
return SECircuitPath::GetResistance();
}
double SEFluidCircuitPath::GetResistance(const FlowResistanceUnit& unit) const
double SEFluidCircuitPath::GetResistance(const PressureTimePerVolumeUnit& unit) const
{
if (m_Resistance == nullptr)
return SEScalar::dNaN();
......@@ -48,11 +48,11 @@ bool SEFluidCircuitPath::HasNextResistance() const
{
return SECircuitPath::HasNextResistance();
}
SEScalarFlowResistance& SEFluidCircuitPath::GetNextResistance()
SEScalarPressureTimePerVolume& SEFluidCircuitPath::GetNextResistance()
{
return SECircuitPath::GetNextResistance();
}
double SEFluidCircuitPath::GetNextResistance(const FlowResistanceUnit& unit) const
double SEFluidCircuitPath::GetNextResistance(const PressureTimePerVolumeUnit& unit) const
{
if (m_NextResistance == nullptr)
return SEScalar::dNaN();
......@@ -62,11 +62,11 @@ bool SEFluidCircuitPath::HasResistanceBaseline() const
{
return SECircuitPath::HasResistanceBaseline();
}
SEScalarFlowResistance& SEFluidCircuitPath::GetResistanceBaseline()
SEScalarPressureTimePerVolume& SEFluidCircuitPath::GetResistanceBaseline()
{
return SECircuitPath::GetResistanceBaseline();
}
double SEFluidCircuitPath::GetResistanceBaseline(const FlowResistanceUnit& unit) const
double SEFluidCircuitPath::GetResistanceBaseline(const PressureTimePerVolumeUnit& unit) const
{
if (m_ResistanceBaseline == nullptr)
return SEScalar::dNaN();
......@@ -81,11 +81,11 @@ bool SEFluidCircuitPath::HasCompliance() const
{
return HasCapacitance();
}
SEScalarFlowCompliance& SEFluidCircuitPath::GetCompliance()
SEScalarVolumePerPressure& SEFluidCircuitPath::GetCompliance()
{
return GetCapacitance();
}
double SEFluidCircuitPath::GetCompliance(const FlowComplianceUnit& unit) const
double SEFluidCircuitPath::GetCompliance(const VolumePerPressureUnit& unit) const
{
if (m_Capacitance == nullptr)
return SEScalar::dNaN();
......@@ -95,11 +95,11 @@ bool SEFluidCircuitPath::HasNextCompliance() const
{
return HasNextCapacitance();
}
SEScalarFlowCompliance& SEFluidCircuitPath::GetNextCompliance()
SEScalarVolumePerPressure& SEFluidCircuitPath::GetNextCompliance()
{
return GetNextCapacitance();
}
double SEFluidCircuitPath::GetNextCompliance(const FlowComplianceUnit& unit) const
double SEFluidCircuitPath::GetNextCompliance(const VolumePerPressureUnit& unit) const
{
if (m_NextCapacitance == nullptr)
return SEScalar::dNaN();
......@@ -109,11 +109,11 @@ bool SEFluidCircuitPath::HasComplianceBaseline() const
{
return HasCapacitanceBaseline();
}
SEScalarFlowCompliance& SEFluidCircuitPath::GetComplianceBaseline()
SEScalarVolumePerPressure& SEFluidCircuitPath::GetComplianceBaseline()
{
return GetCapacitanceBaseline();
}
double SEFluidCircuitPath::GetComplianceBaseline(const FlowComplianceUnit& unit) const
double SEFluidCircuitPath::GetComplianceBaseline(const VolumePerPressureUnit& unit) const
{
if (m_CapacitanceBaseline == nullptr)
return SEScalar::dNaN();
......@@ -128,11 +128,11 @@ bool SEFluidCircuitPath::HasInertance() const
{
return HasInductance();
}
SEScalarFlowInertance& SEFluidCircuitPath::GetInertance()
SEScalarPressureTimeSquaredPerVolume& SEFluidCircuitPath::GetInertance()
{
return GetInductance();
}
double SEFluidCircuitPath::GetInertance(const FlowInertanceUnit& unit) const
double SEFluidCircuitPath::GetInertance(const PressureTimeSquaredPerVolumeUnit& unit) const
{
if (m_Inductance == nullptr)
return SEScalar::dNaN();
......@@ -142,11 +142,11 @@ bool SEFluidCircuitPath::HasNextInertance() const
{
return HasNextInductance();
}
SEScalarFlowInertance& SEFluidCircuitPath::GetNextInertance()
SEScalarPressureTimeSquaredPerVolume& SEFluidCircuitPath::GetNextInertance()
{
return GetNextInductance();
}
double SEFluidCircuitPath::GetNextInertance(const FlowInertanceUnit& unit) const
double SEFluidCircuitPath::GetNextInertance(const PressureTimeSquaredPerVolumeUnit& unit) const
{
if (m_NextInductance == nullptr)
return SEScalar::dNaN();
......@@ -156,11 +156,11 @@ bool SEFluidCircuitPath::HasInertanceBaseline() const
{
return HasInductanceBaseline();
}
SEScalarFlowInertance& SEFluidCircuitPath::GetInertanceBaseline()
SEScalarPressureTimeSquaredPerVolume& SEFluidCircuitPath::GetInertanceBaseline()
{
return GetInductanceBaseline();
}
double SEFluidCircuitPath::GetInertanceBaseline(const FlowInertanceUnit& unit) const
double SEFluidCircuitPath::GetInertanceBaseline(const PressureTimeSquaredPerVolumeUnit& unit) const
{
if (m_InductanceBaseline == nullptr)
return SEScalar::dNaN();
......
......@@ -20,34 +20,34 @@ public:
virtual SEFluidCircuitNode& GetTargetNode() const { return m_FluidTargetNode; }
virtual bool HasResistance() const;
virtual SEScalarFlowResistance& GetResistance();
virtual double GetResistance(const FlowResistanceUnit& unit) const;
virtual SEScalarPressureTimePerVolume& GetResistance();
virtual double GetResistance(const PressureTimePerVolumeUnit& unit) const;
virtual bool HasNextResistance() const;
virtual SEScalarFlowResistance& GetNextResistance();
virtual double GetNextResistance(const FlowResistanceUnit& unit) const;
virtual SEScalarPressureTimePerVolume& GetNextResistance();
virtual double GetNextResistance(const PressureTimePerVolumeUnit& unit) const;
virtual bool HasResistanceBaseline() const;
virtual SEScalarFlowResistance& GetResistanceBaseline();
virtual double GetResistanceBaseline(const FlowResistanceUnit& unit) const;
virtual SEScalarPressureTimePerVolume& GetResistanceBaseline();
virtual double GetResistanceBaseline(const PressureTimePerVolumeUnit& unit) const;
virtual bool HasCompliance() const;
virtual SEScalarFlowCompliance& GetCompliance();
virtual double GetCompliance(const FlowComplianceUnit& unit) const;
virtual SEScalarVolumePerPressure& GetCompliance();
virtual double GetCompliance(const VolumePerPressureUnit& unit) const;
virtual bool HasNextCompliance() const;
virtual SEScalarFlowCompliance& GetNextCompliance();
virtual double GetNextCompliance(const FlowComplianceUnit& unit) const;
virtual SEScalarVolumePerPressure& GetNextCompliance();
virtual double GetNextCompliance(const VolumePerPressureUnit& unit) const;
virtual bool HasComplianceBaseline() const;
virtual SEScalarFlowCompliance& GetComplianceBaseline();
virtual double GetComplianceBaseline(const FlowComplianceUnit& unit) const;
virtual SEScalarVolumePerPressure& GetComplianceBaseline();
virtual double GetComplianceBaseline(const VolumePerPressureUnit& unit) const;
virtual bool HasInertance() const;
virtual SEScalarFlowInertance& GetInertance();
virtual double GetInertance(const FlowInertanceUnit& unit) const;
virtual SEScalarPressureTimeSquaredPerVolume& GetInertance();
virtual double GetInertance(const PressureTimeSquaredPerVolumeUnit& unit) const;
virtual bool HasNextInertance() const;
virtual SEScalarFlowInertance& GetNextInertance();
virtual double GetNextInertance(const FlowInertanceUnit& unit) const;
virtual SEScalarPressureTimeSquaredPerVolume& GetNextInertance();
virtual double GetNextInertance(const PressureTimeSquaredPerVolumeUnit& unit) const;
virtual bool HasInertanceBaseline() const;
virtual SEScalarFlowInertance& GetInertanceBaseline();
virtual double GetInertanceBaseline(const FlowInertanceUnit& unit) const;
virtual SEScalarPressureTimeSquaredPerVolume& GetInertanceBaseline();
virtual double GetInertanceBaseline(const PressureTimeSquaredPerVolumeUnit& unit) const;
virtual bool HasFlow() const;
virtual SEScalarVolumePerTime& GetFlow();
......
......@@ -26,14 +26,14 @@ public:
virtual std::string GetName() const { return m_Name; }
virtual bool HasCompliance() const;
virtual double GetCompliance(const FlowComplianceUnit& unit) const;
virtual double GetCompliance(const VolumePerPressureUnit& unit) const;
virtual bool HasFlow() const;
virtual SEScalarVolumePerTime& GetFlow();
virtual double GetFlow(const VolumePerTimeUnit& unit) const;
virtual bool HasResistance() const;
virtual double GetResistance(const FlowResistanceUnit& unit) const;
virtual double GetResistance(const PressureTimePerVolumeUnit& unit) const;
virtual CompartmentType& GetSourceCompartment() { return m_SourceCmpt; }
virtual CompartmentType& GetTargetCompartment() { return m_TargetCmpt; }
......
......@@ -44,7 +44,7 @@ bool SEFluidCompartmentLink<FLUID_COMPARTMENT_LINK_TYPES>::HasCompliance() const
return false;
}
template<FLUID_COMPARTMENT_LINK_TEMPLATE>
double SEFluidCompartmentLink<FLUID_COMPARTMENT_LINK_TYPES>::GetCompliance(const FlowComplianceUnit& unit) const
double SEFluidCompartmentLink<FLUID_COMPARTMENT_LINK_TYPES>::GetCompliance(const VolumePerPressureUnit& unit) const
{
if (m_Path != nullptr)
return m_Path->GetNextCompliance(unit);
......@@ -86,7 +86,7 @@ bool SEFluidCompartmentLink<FLUID_COMPARTMENT_LINK_TYPES>::HasResistance() const
return false;
}
template<FLUID_COMPARTMENT_LINK_TEMPLATE>
double SEFluidCompartmentLink<FLUID_COMPARTMENT_LINK_TYPES>::GetResistance(const FlowResistanceUnit& unit) const
double SEFluidCompartmentLink<FLUID_COMPARTMENT_LINK_TYPES>::GetResistance(const PressureTimePerVolumeUnit& unit) const
{
if (m_Path != nullptr)
return m_Path->GetNextResistance(unit);
......
......@@ -21,10 +21,10 @@
#include "properties/SEScalarEnergy.h"
#include "properties/SEScalarEnergyPerAmount.h"
#include "properties/SEScalarEnergyPerMass.h"
#include "properties/SEScalarFlowCompliance.h"
#include "properties/SEScalarFlowElastance.h"
#include "properties/SEScalarFlowInertance.h"
#include "properties/SEScalarFlowResistance.h"
#include "properties/SEScalarVolumePerPressure.h"
#include "properties/SEScalarPressurePerVolume.h"
#include "properties/SEScalarPressureTimeSquaredPerVolume.h"
#include "properties/SEScalarPressureTimePerVolume.h"
#include "properties/SEScalarForce.h"
#include "properties/SEScalarFrequency.h"
#include "properties/SEScalarHeatCapacitance.h"
......@@ -456,90 +456,6 @@ void PBProperty::Serialize(const SEScalarEnergyPerMass& src, cdm::ScalarEnergyPe
PBProperty::Serialize(src, *dst.mutable_scalarenergypermass());
}
void PBProperty::Load(const cdm::ScalarFlowComplianceData& src, SEScalarFlowCompliance& dst)
{
PBProperty::Serialize(src, dst);
}
void PBProperty::Serialize(const cdm::ScalarFlowComplianceData& src, SEScalarFlowCompliance& dst)
{
PBProperty::Serialize(src.scalarflowcompliance(), dst);
}
cdm::ScalarFlowComplianceData* PBProperty::Unload(const SEScalarFlowCompliance& src)
{
if (!src.IsValid())
return nullptr;
cdm::ScalarFlowComplianceData* dst = new cdm::ScalarFlowComplianceData();
PBProperty::Serialize(src, *dst);
return dst;
}
void PBProperty::Serialize(const SEScalarFlowCompliance& src, cdm::ScalarFlowComplianceData& dst)
{
PBProperty::Serialize(src, *dst.mutable_scalarflowcompliance());
}
void PBProperty::Load(const cdm::ScalarFlowElastanceData& src, SEScalarFlowElastance& dst)
{
PBProperty::Serialize(src, dst);
}
void PBProperty::Serialize(const cdm::ScalarFlowElastanceData& src, SEScalarFlowElastance& dst)
{
PBProperty::Serialize(src.scalarflowelastance(), dst);
}
cdm::ScalarFlowElastanceData* PBProperty::Unload(const SEScalarFlowElastance& src)
{
if (!src.IsValid())
return nullptr;
cdm::ScalarFlowElastanceData* dst = new cdm::ScalarFlowElastanceData();
PBProperty::Serialize(src, *dst);
return dst;
}
void PBProperty::Serialize(const SEScalarFlowElastance& src, cdm::ScalarFlowElastanceData& dst)
{
PBProperty::Serialize(src, *dst.mutable_scalarflowelastance());
}
void PBProperty::Load(const cdm::ScalarFlowInertanceData& src, SEScalarFlowInertance& dst)
{
PBProperty::Serialize(src, dst);
}
void PBProperty::Serialize(const cdm::ScalarFlowInertanceData& src, SEScalarFlowInertance& dst)
{
PBProperty::Serialize(src.scalarflowinertance(), dst);
}
cdm::ScalarFlowInertanceData* PBProperty::Unload(const SEScalarFlowInertance& src)
{
if (!src.IsValid())
return nullptr;
cdm::ScalarFlowInertanceData* dst = new cdm::ScalarFlowInertanceData();
PBProperty::Serialize(src, *dst);
return dst;
}
void PBProperty::Serialize(const SEScalarFlowInertance& src, cdm::ScalarFlowInertanceData& dst)
{
PBProperty::Serialize(src, *dst.mutable_scalarflowinertance());
}
void PBProperty::Load(const cdm::ScalarFlowResistanceData& src, SEScalarFlowResistance& dst)
{
PBProperty::Serialize(src, dst);
}
void PBProperty::Serialize(const cdm::ScalarFlowResistanceData& src, SEScalarFlowResistance& dst)
{
PBProperty::Serialize(src.scalarflowresistance(), dst);
}
cdm::ScalarFlowResistanceData* PBProperty::Unload(const SEScalarFlowResistance& src)
{
if (!src.IsValid())
return nullptr;
cdm::ScalarFlowResistanceData* dst = new cdm::ScalarFlowResistanceData();
PBProperty::Serialize(src, *dst);
return dst;
}
void PBProperty::Serialize(const SEScalarFlowResistance& src, cdm::ScalarFlowResistanceData& dst)
{
PBProperty::Serialize(src, *dst.mutable_scalarflowresistance());
}
void PBProperty::Load(const cdm::ScalarForceData& src, SEScalarForce& dst)
{
PBProperty::Serialize(src, dst);
......@@ -1149,6 +1065,27 @@ void PBProperty::Serialize(const SEScalarPressureTimePerArea& src, cdm::ScalarPr
PBProperty::Serialize(src, *dst.mutable_scalarpressuretimeperarea());
}
void PBProperty::Load(const cdm::ScalarPressureTimePerVolumeData& src, SEScalarPressureTimePerVolume& dst)
{
PBProperty::Serialize(src, dst);
}
void PBProperty::Serialize(const cdm::ScalarPressureTimePerVolumeData& src, SEScalarPressureTimePerVolume& dst)
{
PBProperty::Serialize(src.scalarpressuretimepervolume(), dst);
}
cdm::ScalarPressureTimePerVolumeData* PBProperty::Unload(const SEScalarPressureTimePerVolume& src)
{
if (!src.IsValid())
return nullptr;
cdm::ScalarPressureTimePerVolumeData* dst = new cdm::ScalarPressureTimePerVolumeData();
PBProperty::Serialize(src, *dst);
return dst;
}
void PBProperty::Serialize(const SEScalarPressureTimePerVolume& src, cdm::ScalarPressureTimePerVolumeData& dst)
{
PBProperty::Serialize(src, *dst.mutable_scalarpressuretimepervolume());
}
void PBProperty::Load(const cdm::ScalarPressureTimePerVolumeAreaData& src, SEScalarPressureTimePerVolumeArea& dst)
{
PBProperty::Serialize(src, dst);
......@@ -1170,6 +1107,28 @@ void PBProperty::Serialize(const SEScalarPressureTimePerVolumeArea& src, cdm::Sc
PBProperty::Serialize(src, *dst.mutable_scalarpressuretimepervolumearea());
}
void PBProperty::Load(const cdm::ScalarPressureTimeSquaredPerVolumeData& src, SEScalarPressureTimeSquaredPerVolume& dst)
{
PBProperty::Serialize(src, dst);
}
void PBProperty::Serialize(const cdm::ScalarPressureTimeSquaredPerVolumeData& src, SEScalarPressureTimeSquaredPerVolume& dst)
{
PBProperty::Serialize(src.scalarpressuretimesquaredpervolume(), dst);
}
cdm::ScalarPressureTimeSquaredPerVolumeData* PBProperty::Unload(const SEScalarPressureTimeSquaredPerVolume& src)
{
if (!src.IsValid())
return nullptr;
cdm::ScalarPressureTimeSquaredPerVolumeData* dst = new cdm::ScalarPressureTimeSquaredPerVolumeData();
PBProperty::Serialize(src, *dst);
return dst;
}
void PBProperty::Serialize(const SEScalarPressureTimeSquaredPerVolume& src, cdm::ScalarPressureTimeSquaredPerVolumeData& dst)
{
PBProperty::Serialize(src, *dst.mutable_scalarpressuretimesquaredpervolume());
}
void PBProperty::Load(const cdm::ScalarTemperatureData& src, SEScalarTemperature& dst)
{
PBProperty::Serialize(src, dst);
......
......@@ -20,10 +20,6 @@ CDM_BIND_DECL(ScalarElectricResistanceData)
CDM_BIND_DECL(ScalarEnergyData)
CDM_BIND_DECL(ScalarEnergyPerAmountData)
CDM_BIND_DECL(ScalarEnergyPerMassData)
CDM_BIND_DECL(ScalarFlowComplianceData)
CDM_BIND_DECL(ScalarFlowElastanceData)
CDM_BIND_DECL(ScalarFlowInertanceData)
CDM_BIND_DECL(ScalarFlowResistanceData)
CDM_BIND_DECL(ScalarForceData)
CDM_BIND_DECL(ScalarFrequencyData)
CDM_BIND_DECL(ScalarHeatCapacitanceData)
......@@ -52,8 +48,10 @@ CDM_BIND_DECL(ScalarPowerData)
CDM_BIND_DECL(ScalarPowerPerAreaTemperatureToTheFourthData)
CDM_BIND_DECL(ScalarPressureData)
CDM_BIND_DECL(ScalarPressurePerVolumeData)
CDM_BIND_DECL(ScalarPressureTimePerVolumeData)
CDM_BIND_DECL(ScalarPressureTimePerAreaData)
CDM_BIND_DECL(ScalarPressureTimePerVolumeAreaData)
CDM_BIND_DECL(ScalarPressureTimeSquaredPerVolumeData)
CDM_BIND_DECL(ScalarTemperatureData)
CDM_BIND_DECL(ScalarTimeData)
CDM_BIND_DECL(ScalarVolumeData)
......@@ -165,26 +163,6 @@ public:
static void Serialize(const cdm::ScalarEnergyPerMassData& src, SEScalarEnergyPerMass& dst);
static void Serialize(const SEScalarEnergyPerMass& src, cdm::ScalarEnergyPerMassData& dst);
static void Load(const cdm::ScalarFlowComplianceData& src, SEScalarFlowCompliance& dst);
static cdm::ScalarFlowComplianceData* Unload(const SEScalarFlowCompliance& src);
static void Serialize(const cdm::ScalarFlowComplianceData& src, SEScalarFlowCompliance& dst);
static void Serialize(const SEScalarFlowCompliance& src, cdm::ScalarFlowComplianceData& dst);
static void Load(const cdm::ScalarFlowElastanceData& src, SEScalarFlowElastance& dst);
static cdm::ScalarFlowElastanceData* Unload(const SEScalarFlowElastance& src);
static void Serialize(const cdm::ScalarFlowElastanceData& src, SEScalarFlowElastance& dst);
static void Serialize(const SEScalarFlowElastance& src, cdm::ScalarFlowElastanceData& dst);
static void Load(const cdm::ScalarFlowInertanceData& src, SEScalarFlowInertance& dst);
static cdm::ScalarFlowInertanceData* Unload(const SEScalarFlowInertance& src);
static void Serialize(const cdm::ScalarFlowInertanceData& src, SEScalarFlowInertance& dst);
static void Serialize(const SEScalarFlowInertance& src, cdm::ScalarFlowInertanceData& dst);
static void Load(const cdm::ScalarFlowResistanceData& src, SEScalarFlowResistance& dst);
static cdm::ScalarFlowResistanceData* Unload(const SEScalarFlowResistance& src);
static void Serialize(const cdm::ScalarFlowResistanceData& src, SEScalarFlowResistance& dst);
static void Serialize(const SEScalarFlowResistance& src, cdm::ScalarFlowResistanceData& dst);
static void Load(const cdm::ScalarForceData& src, SEScalarForce& dst);
static cdm::ScalarForceData* Unload(const SEScalarForce& src);
static void Serialize(const cdm::ScalarForceData& src, SEScalarForce& dst);
......@@ -330,11 +308,21 @@ public:
static void Serialize(const cdm::ScalarPressureTimePerAreaData& src, SEScalarPressureTimePerArea& dst);
static void Serialize(const SEScalarPressureTimePerArea& src, cdm::ScalarPressureTimePerAreaData& dst);
static void Load(const cdm::ScalarPressureTimePerVolumeData& src, SEScalarPressureTimePerVolume& dst);
static cdm::ScalarPressureTimePerVolumeData* Unload(const SEScalarPressureTimePerVolume& src);
static void Serialize(const cdm::ScalarPressureTimePerVolumeData& src, SEScalarPressureTimePerVolume& dst);
static void Serialize(const SEScalarPressureTimePerVolume& src, cdm::ScalarPressureTimePerVolumeData& dst);
static void Load(const cdm::ScalarPressureTimePerVolumeAreaData& src, SEScalarPressureTimePerVolumeArea& dst);
static cdm::ScalarPressureTimePerVolumeAreaData* Unload(const SEScalarPressureTimePerVolumeArea& src);
static void Serialize(const cdm::ScalarPressureTimePerVolumeAreaData& src, SEScalarPressureTimePerVolumeArea& dst);
static void Serialize(const SEScalarPressureTimePerVolumeArea& src, cdm::ScalarPressureTimePerVolumeAreaData& dst);
static void Load(const cdm::ScalarPressureTimeSquaredPerVolumeData& src, SEScalarPressureTimeSquaredPerVolume& dst);
static cdm::ScalarPressureTimeSquaredPerVolumeData* Unload(const SEScalarPressureTimeSquaredPerVolume& src);
static void Serialize(const cdm::ScalarPressureTimeSquaredPerVolumeData& src, SEScalarPressureTimeSquaredPerVolume& dst);
static void Serialize(const SEScalarPressureTimeSquaredPerVolume& src, cdm::ScalarPressureTimeSquaredPerVolumeData& dst);
static void Load(const cdm::ScalarTemperatureData& src, SEScalarTemperature& dst);
static cdm::ScalarTemperatureData* Unload(const SEScalarTemperature& src);
static void Serialize(const cdm::ScalarTemperatureData& src, SEScalarTemperature& dst);
......
......@@ -18,7 +18,7 @@
#include "properties/SEScalarVolumePerTime.h"
#include "properties/SEScalarArea.h"
#include "properties/SEScalarPower.h"
#include "properties/SEScalarFlowElastance.h"
#include "properties/SEScalarPressurePerVolume.h"
#include "io/protobuf/PBPatient.h"
......
......@@ -33,10 +33,10 @@ void SEProperty::Clear()
#include "properties/SEScalarEnergy.h"
#include "properties/SEScalarEnergyPerAmount.h"
#include "properties/SEScalarEnergyPerMass.h"
#include "properties/SEScalarFlowCompliance.h"
#include "properties/SEScalarFlowElastance.h"
#include "properties/SEScalarFlowInertance.h"
#include "properties/SEScalarFlowResistance.h"
#include "properties/SEScalarVolumePerPressure.h"
#include "properties/SEScalarPressurePerVolume.h"
#include "properties/SEScalarPressureTimeSquaredPerVolume.h"
#include "properties/SEScalarPressureTimePerVolume.h"
#include "properties/SEScalarForce.h"
#include "properties/SEScalarFrequency.h"
#include "properties/SEScalarHeatCapacitance.h"
......@@ -130,10 +130,10 @@ const CCompoundUnit& GetUnit(const std::string& unit)
IS_A(EnergyUnit);
IS_A(EnergyPerAmountUnit);
IS_A(EnergyPerMassUnit);
IS_A(FlowComplianceUnit);
IS_A(FlowElastanceUnit);
IS_A(FlowInertanceUnit);
IS_A(FlowResistanceUnit);
IS_A(VolumePerPressureUnit);
IS_A(PressurePerVolumeUnit);
IS_A(PressureTimeSquaredPerVolumeUnit);
IS_A(PressureTimePerVolumeUnit);
IS_A(ForceUnit);
IS_A(FrequencyUnit);
IS_A(HeatCapacitanceUnit);
......