SESleep.h
1 /**************************************************************************************
2 Copyright 2015 Applied Research Associates, Inc.
3 Licensed under the Apache License, Version 2.0 (the "License"); you may not use
4 this file except in compliance with the License. You may obtain a copy of the License
5 at:
6 http://www.apache.org/licenses/LICENSE-2.0
7 Unless required by applicable law or agreed to in writing, software distributed under
8 the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
9 CONDITIONS OF ANY KIND, either express or implied. See the License for the
10 specific language governing permissions and limitations under the License.
11 **************************************************************************************/
12 
13 #pragma once
14 
15 #include <biogears/cdm/CommonDataModel.h>
16 #include <biogears/exports.h>
17 #include <biogears/cdm/patient/actions/SEPatientAction.h>
18 #include <biogears/schema/cdm/PatientActions.hxx>
19 
20 namespace biogears {
21 
22 class BIOGEARS_API SESleep : public SEPatientAction {
23 public:
24  SESleep();
25  virtual ~SESleep() override;
26 
27  static constexpr const char* TypeTag() { return "SESleep"; };
28  const char* classname() const override { return TypeTag(); }
29 
30  virtual void Clear() override; //clear memory
31 
32  virtual bool IsValid() const override;
33  virtual bool IsActive() const override;
34 
35  virtual bool Load(const CDM::SleepData& in);
36  virtual CDM::SleepData* Unload() const override;
37 
38 protected:
39  virtual void Unload(CDM::SleepData& data) const;
40 
41 public:
42 
43 
44  virtual bool HasSleepState() const;
45  virtual CDM::enumOnOff GetSleepState();
46  virtual void SetSleepState(CDM::enumOnOff::value t);
47 
48  virtual void ToString(std::ostream& str) const override;
49 
50 protected:
52 
53 
54 };
55 }
const char * classname() const override
Definition: SESleep.h:28
Definition: SEPatientAction.h:18
Class corresponding to the SleepData schema type.
Definition: PatientActions.hxx:9282
CDM::enumOnOff::value m_SleepState
Definition: SESleep.h:51
static constexpr const char * TypeTag()
Definition: SESleep.h:27
Enumeration class corresponding to the enumOnOff schema type.
Definition: Properties.hxx:2063
Definition: SESleep.h:22
value
Underlying enum type.
Definition: Properties.hxx:2070
Definition: SEElectricalCircuit.h:18