SEEnvironmentActionCollection.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 #include <biogears/cdm/substance/SESubstanceManager.h>
15 #include <biogears/cdm/system/environment/actions/SEEnvironmentChange.h>
16 #include <biogears/cdm/system/environment/actions/SEThermalApplication.h>
17 #include <biogears/schema/cdm/EnvironmentActions.hxx>
18 
19 namespace biogears {
20 class BIOGEARS_API SEEnvironmentActionCollection : public Loggable {
21 public:
24 
25  void Clear();
26 
27  void Unload(std::vector<CDM::ActionData*>& to);
28 
29  bool ProcessAction(const SEEnvironmentAction& action);
30  bool ProcessAction(const CDM::EnvironmentActionData& action);
31 
32  // STATE ACTION
33  bool HasChange() const;
34  SEEnvironmentChange* GetChange() const;
35  void RemoveChange();
36 
37  bool HasThermalApplication() const;
38  SEThermalApplication* GetThermalApplication() const;
39  void RemoveThermalApplication();
40 
41 protected:
42  bool IsValid(const SEEnvironmentAction& action);
43 
46  // General
48  std::stringstream m_ss;
49 };
50 }
SEEnvironmentChange * m_Change
Definition: SEEnvironmentActionCollection.h:44
Definition: SEEnvironmentActionCollection.h:20
std::stringstream m_ss
Definition: SEEnvironmentActionCollection.h:48
SESubstanceManager & m_Substances
Definition: SEEnvironmentActionCollection.h:47
Definition: SEEnvironmentChange.h:18
Definition: Logger.h:27
Class corresponding to the EnvironmentActionData schema type.
Definition: EnvironmentActions.hxx:686
Definition: SEEnvironmentAction.h:17
SEThermalApplication * m_ThermalApplication
Definition: SEEnvironmentActionCollection.h:45
Definition: SESubstanceManager.h:23
Definition: SEElectricalCircuit.h:18
Definition: SEThermalApplication.h:21