SEElectroCardioGram.h
1/* Distributed under the Apache License, Version 2.0.
2 See accompanying NOTICE file for details.*/
3
4#pragma once
5#include "cdm/system/equipment/SEEquipment.h"
6#include "cdm/system/equipment/electrocardiogram/SEElectroCardioGramWaveform.h"
7
8class CDM_DECL SEElectroCardioGram : public SEEquipment
9{
10 friend class PBElectroCardioGram;//friend the serialization class
11protected:
12
13public:
14
16 virtual ~SEElectroCardioGram();
17
18 void Clear() override;
19
20 void Copy(const SEElectroCardioGram& src);
21
22 const SEScalar* GetScalar(const std::string& name) override;
23
24 bool SerializeToString(std::string& output, eSerializationFormat m) const;
25 bool SerializeToFile(const std::string& filename) const;
26 bool SerializeFromString(const std::string& src, eSerializationFormat m);
27 bool SerializeFromFile(const std::string& filename);
28
29 virtual bool HasLead1ElectricPotential() const;
30 virtual SEScalarElectricPotential& GetLead1ElectricPotential();
31 virtual double GetLead1ElectricPotential(const ElectricPotentialUnit& unit) const;
32
33 virtual bool HasLead2ElectricPotential() const;
34 virtual SEScalarElectricPotential& GetLead2ElectricPotential();
35 virtual double GetLead2ElectricPotential(const ElectricPotentialUnit& unit) const;
36
37 virtual bool HasLead3ElectricPotential() const;
38 virtual SEScalarElectricPotential& GetLead3ElectricPotential();
39 virtual double GetLead3ElectricPotential(const ElectricPotentialUnit& unit) const;
40
41 virtual bool HasLead4ElectricPotential() const;
42 virtual SEScalarElectricPotential& GetLead4ElectricPotential();
43 virtual double GetLead4ElectricPotential(const ElectricPotentialUnit& unit) const;
44
45 virtual bool HasLead5ElectricPotential() const;
46 virtual SEScalarElectricPotential& GetLead5ElectricPotential();
47 virtual double GetLead5ElectricPotential(const ElectricPotentialUnit& unit) const;
48
49 virtual bool HasLead6ElectricPotential() const;
50 virtual SEScalarElectricPotential& GetLead6ElectricPotential();
51 virtual double GetLead6ElectricPotential(const ElectricPotentialUnit& unit) const;
52
53 virtual bool HasLead7ElectricPotential() const;
54 virtual SEScalarElectricPotential& GetLead7ElectricPotential();
55 virtual double GetLead7ElectricPotential(const ElectricPotentialUnit& unit) const;
56
57 virtual bool HasLead8ElectricPotential() const;
58 virtual SEScalarElectricPotential& GetLead8ElectricPotential();
59 virtual double GetLead8ElectricPotential(const ElectricPotentialUnit& unit) const;
60
61 virtual bool HasLead9ElectricPotential() const;
62 virtual SEScalarElectricPotential& GetLead9ElectricPotential();
63 virtual double GetLead9ElectricPotential(const ElectricPotentialUnit& unit) const;
64
65 virtual bool HasLead10ElectricPotential() const;
66 virtual SEScalarElectricPotential& GetLead10ElectricPotential();
67 virtual double GetLead10ElectricPotential(const ElectricPotentialUnit& unit) const;
68
69 virtual bool HasLead11ElectricPotential() const;
70 virtual SEScalarElectricPotential& GetLead11ElectricPotential();
71 virtual double GetLead11ElectricPotential(const ElectricPotentialUnit& unit) const;
72
73 virtual bool HasLead12ElectricPotential() const;
74 virtual SEScalarElectricPotential& GetLead12ElectricPotential();
75 virtual double GetLead12ElectricPotential(const ElectricPotentialUnit& unit) const;
76
77 virtual bool HasWaveforms();
78 virtual bool HasWaveform(eElectroCardioGram_WaveformLead, eElectroCardioGram_WaveformType);
79 virtual SEElectroCardioGramWaveform& GetWaveform(eElectroCardioGram_WaveformLead, eElectroCardioGram_WaveformType);
80 virtual const SEElectroCardioGramWaveform* GetWaveform(eElectroCardioGram_WaveformLead, eElectroCardioGram_WaveformType) const;
81
82 virtual eElectroCardioGram_WaveformType GetActiveType() { return m_ActiveType; }
83 virtual void ClearCycles();
84 virtual void PullCycleValues();
85 virtual void StartNewCycle(eElectroCardioGram_WaveformType t, const SEScalarFrequency& hr, const SEScalarTime& dt, double amplitudeModifier);
86
87protected:
88 virtual std::vector<SEElectroCardioGramWaveform*>& GetWaveforms();
89
102
103 eElectroCardioGram_WaveformType m_ActiveType;
104 std::vector<SEElectroCardioGramWaveform*> m_Waveforms;
105};
Definition: SEScalarElectricPotential.h:8
Definition: Logger.h:71
Definition: PBElectroCardioGram.h:10
static bool SerializeFromFile(const std::string &filename, SEElectroCardioGram &dst)
Definition: PBElectroCardioGram.cpp:124
static void Copy(const SEElectroCardioGram &src, SEElectroCardioGram &dst)
Definition: PBElectroCardioGram.cpp:96
static bool SerializeToFile(const SEElectroCardioGram &src, const std::string &filename)
Definition: PBElectroCardioGram.cpp:110
static bool SerializeFromString(const std::string &src, SEElectroCardioGram &dst, eSerializationFormat m)
Definition: PBElectroCardioGram.cpp:116
static bool SerializeToString(const SEElectroCardioGram &src, std::string &output, eSerializationFormat m)
Definition: PBElectroCardioGram.cpp:104
Definition: SEElectroCardioGram.h:9
SEScalarElectricPotential * m_Lead9ElectricPotential
Definition: SEElectroCardioGram.h:98
SEScalarElectricPotential * m_Lead3ElectricPotential
Definition: SEElectroCardioGram.h:92
SEScalarElectricPotential * m_Lead5ElectricPotential
Definition: SEElectroCardioGram.h:94
SEScalarElectricPotential * m_Lead4ElectricPotential
Definition: SEElectroCardioGram.h:93
SEScalarElectricPotential * m_Lead8ElectricPotential
Definition: SEElectroCardioGram.h:97
SEScalarElectricPotential * m_Lead12ElectricPotential
Definition: SEElectroCardioGram.h:101
virtual eElectroCardioGram_WaveformType GetActiveType()
Definition: SEElectroCardioGram.h:82
SEScalarElectricPotential * m_Lead1ElectricPotential
Definition: SEElectroCardioGram.h:90
SEScalarElectricPotential * m_Lead2ElectricPotential
Definition: SEElectroCardioGram.h:91
SEScalarElectricPotential * m_Lead6ElectricPotential
Definition: SEElectroCardioGram.h:95
std::vector< SEElectroCardioGramWaveform * > m_Waveforms
Definition: SEElectroCardioGram.h:104
SEScalarElectricPotential * m_Lead10ElectricPotential
Definition: SEElectroCardioGram.h:99
SEScalarElectricPotential * m_Lead7ElectricPotential
Definition: SEElectroCardioGram.h:96
eElectroCardioGram_WaveformType m_ActiveType
Definition: SEElectroCardioGram.h:103
SEScalarElectricPotential * m_Lead11ElectricPotential
Definition: SEElectroCardioGram.h:100
Definition: SEElectroCardioGramWaveform.h:30
Definition: SEEquipment.h:9
void Clear() override
Definition: SEEquipment.cpp:17
Definition: SEScalarElectricPotential.h:25
Definition: SEScalarFrequency.h:26
Definition: SEScalar.h:19
Definition: SEScalarTime.h:28
virtual const SEScalar * GetScalar(const std::string &name)=0

Distributed under the Apache License, Version 2.0.

See accompanying NOTICE file for details.