GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 100.0% 2 / 1 / 3
Functions: 100.0% 1 / 1 / 2
Branches: -% 0 / 1 / 1

src/utilities/filetypes/ForwardTranslatorOptions.hpp
Line Branch Exec Source
1 /***********************************************************************************************************************
2 * OpenStudio(R), Copyright (c) Alliance for Energy Innovation, LLC.
3 * See also https://openstudio.net/license
4 ***********************************************************************************************************************/
5
6 #ifndef UTILITIES_FILETYPES_FORWARDTRANSLATOROPTIONS_HPP
7 #define UTILITIES_FILETYPES_FORWARDTRANSLATOROPTIONS_HPP
8
9 #include "../UtilitiesAPI.hpp"
10
11 #include "../core/Logger.hpp"
12
13 namespace Json {
14 class Value;
15 }
16
17 namespace openstudio {
18 namespace detail {
19 class WorkflowJSON_Impl;
20 class RunOptions_Impl;
21 class ForwardTranslatorOptions_Impl;
22 } // namespace detail
23
24 struct ForwardTranslatorOptionKeyMethod
25 {
26 std::string json_name;
27 std::string ft_method_name;
28 };
29 UTILITIES_API std::ostream& operator<<(std::ostream& out, const ForwardTranslatorOptionKeyMethod& opt);
30
31 class UTILITIES_API ForwardTranslatorOptions
32 {
33 public:
34 ForwardTranslatorOptions();
35
36 void reset();
37
38 /// Construct from JSON formatted string
39 static boost::optional<ForwardTranslatorOptions> fromString(const std::string& s);
40
41 Json::Value toJSON() const;
42
43 /// Serialize to JSON formatted string
44 std::string string() const;
45
46 bool keepRunControlSpecialDays() const;
47 bool isKeepRunControlSpecialDaysDefaulted() const;
48 void setKeepRunControlSpecialDays(bool keepRunControlSpecialDays);
49 void resetKeepRunControlSpecialDays();
50
51 bool iPTabularOutput() const;
52 bool isIPTabularOutputDefaulted() const;
53 void setIPTabularOutput(bool iPTabularOutput);
54 void resetIPTabularOutput();
55
56 bool excludeLCCObjects() const;
57 bool isExcludeLCCObjectsDefaulted() const;
58 void setExcludeLCCObjects(bool excludeLCCObjects);
59 void resetExcludeLCCObjects();
60
61 bool excludeSQliteOutputReport() const;
62 bool isExcludeSQliteOutputReportDefaulted() const;
63 void setExcludeSQliteOutputReport(bool excludeSQliteOutputReport);
64 void resetExcludeSQliteOutputReport();
65
66 bool excludeHTMLOutputReport() const;
67 bool isExcludeHTMLOutputReportDefaulted() const;
68 void setExcludeHTMLOutputReport(bool excludeHTMLOutputReport);
69 void resetExcludeHTMLOutputReport();
70
71 bool excludeVariableDictionary() const;
72 bool isExcludeVariableDictionaryDefaulted() const;
73 void setExcludeVariableDictionary(bool excludeVariableDictionary);
74 void resetExcludeVariableDictionary();
75
76 bool excludeSpaceTranslation() const;
77 bool isExcludeSpaceTranslationDefaulted() const;
78 void setExcludeSpaceTranslation(bool excludeSpaceTranslation);
79 void resetExcludeSpaceTranslation();
80
81 bool excludeSpaceLoadInstances() const;
82 bool isExcludeSpaceLoadInstancesDefaulted() const;
83 void setExcludeSpaceLoadInstances(bool excludeSpaceLoadInstances);
84 void resetExcludeSpaceLoadInstances();
85
86 bool excludeConstructionAssignmentSets() const;
87 bool isExcludeConstructionAssignmentSetsDefaulted() const;
88 void setExcludeConstructionAssignmentSets(bool excludeConstructionAssignmentSets);
89 void resetExcludeConstructionAssignmentSets();
90
91 /* Any non-defaulted value from other is brought over */
92 void overrideValuesWith(const ForwardTranslatorOptions& other);
93
94 // TODO: keep?
95 static std::vector<ForwardTranslatorOptionKeyMethod> forwardTranslatorOptionKeyMethods();
96
97 protected:
98 static ForwardTranslatorOptions fromJSON(const Json::Value& value);
99
100 // get the impl
101 2 std::shared_ptr<detail::ForwardTranslatorOptions_Impl> getImpl() const {
102 2 return m_impl;
103 }
104
105 explicit ForwardTranslatorOptions(std::shared_ptr<detail::ForwardTranslatorOptions_Impl> impl);
106
107 friend class detail::ForwardTranslatorOptions_Impl;
108 friend class RunOptions;
109 friend class detail::RunOptions_Impl;
110
111 private:
112 // configure logging
113 − REGISTER_LOGGER("openstudio.ForwardTranslatorOptions");
114
115 // pointer to implementation
116 std::shared_ptr<detail::ForwardTranslatorOptions_Impl> m_impl;
117 };
118
119 UTILITIES_API std::ostream& operator<<(std::ostream& os, const ForwardTranslatorOptions& forwardTranslatorOptions);
120
121 } // namespace openstudio
122
123 #endif // UTILITIES_FILETYPES_FORWARDTRANSLATOROPTIONS_HPP
124