F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
AssertFatalAdapterComponentAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title AssertFatalAdapterComponentAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for AssertFatalAdapter component base class
5 // ======================================================================
6 
7 #ifndef Svc_AssertFatalAdapterComponentAc_HPP
8 #define Svc_AssertFatalAdapterComponentAc_HPP
9 
10 #include <atomic>
11 
13 #include "Fw/FPrimeBasicTypes.hpp"
14 #include "Fw/Log/LogPortAc.hpp"
15 #include "Fw/Log/LogString.hpp"
16 #if FW_ENABLE_TEXT_LOGGING == 1
17 #include "Fw/Log/LogTextPortAc.hpp"
18 #endif
21 #include "Fw/Time/TimePortAc.hpp"
22 
23 namespace Svc {
24 
31  {
32 
33  // ----------------------------------------------------------------------
34  // Friend classes
35  // ----------------------------------------------------------------------
36 
41 
42  PROTECTED:
43 
44  // ----------------------------------------------------------------------
45  // Constants
46  // ----------------------------------------------------------------------
47 
49  enum {
53  };
54 
56  enum {
65  };
66 
67  public:
68 
69  // ----------------------------------------------------------------------
70  // Component initialization
71  // ----------------------------------------------------------------------
72 
74  void init(
75  FwEnumStoreType instance = 0
76  );
77 
78  public:
79 
80  // ----------------------------------------------------------------------
81  // Connect input ports to special output ports
82  // ----------------------------------------------------------------------
83 
85  void set_Log_OutputPort(
86  FwIndexType portNum,
87  Fw::InputLogPort* port
88  );
89 
90 #if FW_ENABLE_TEXT_LOGGING == 1
91 
93  void set_LogText_OutputPort(
94  FwIndexType portNum,
96  );
97 
98 #endif
99 
101  void set_Time_OutputPort(
102  FwIndexType portNum,
103  Fw::InputTimePort* port
104  );
105 
106 #if FW_PORT_SERIALIZATION
107 
108  public:
109 
110  // ----------------------------------------------------------------------
111  // Connect serial input ports to special output ports
112  // ----------------------------------------------------------------------
113 
115  void set_Log_OutputPort(
116  FwIndexType portNum,
117  Fw::InputSerializePort* port
118  );
119 
120 #if FW_ENABLE_TEXT_LOGGING == 1
121 
123  void set_LogText_OutputPort(
124  FwIndexType portNum,
125  Fw::InputSerializePort* port
126  );
127 
128 #endif
129 
131  void set_Time_OutputPort(
132  FwIndexType portNum,
133  Fw::InputSerializePort* port
134  );
135 
136 #endif
137 
138  PROTECTED:
139 
140  // ----------------------------------------------------------------------
141  // Component construction and destruction
142  // ----------------------------------------------------------------------
143 
146  const char* compName = ""
147  );
148 
151 
152  PROTECTED:
153 
154  // ----------------------------------------------------------------------
155  // Getters for numbers of special output ports
156  // ----------------------------------------------------------------------
157 
162 
163 #if FW_ENABLE_TEXT_LOGGING == 1
164 
168  FwIndexType getNum_LogText_OutputPorts() const;
169 
170 #endif
171 
176 
177  PROTECTED:
178 
179  // ----------------------------------------------------------------------
180  // Connection status queries for special output ports
181  // ----------------------------------------------------------------------
182 
187  FwIndexType portNum
188  );
189 
190 #if FW_ENABLE_TEXT_LOGGING == 1
191 
195  bool isConnected_LogText_OutputPort(
196  FwIndexType portNum
197  );
198 
199 #endif
200 
205  FwIndexType portNum
206  );
207 
208  PROTECTED:
209 
210  // ----------------------------------------------------------------------
211  // Event logging functions
212  // ----------------------------------------------------------------------
213 
218  const Fw::StringBase& file,
219  U32 line
220  ) const;
221 
226  const Fw::StringBase& file,
227  U32 line,
228  U32 arg1
229  ) const;
230 
235  const Fw::StringBase& file,
236  U32 line,
237  U32 arg1,
238  U32 arg2
239  ) const;
240 
245  const Fw::StringBase& file,
246  U32 line,
247  U32 arg1,
248  U32 arg2,
249  U32 arg3
250  ) const;
251 
256  const Fw::StringBase& file,
257  U32 line,
258  U32 arg1,
259  U32 arg2,
260  U32 arg3,
261  U32 arg4
262  ) const;
263 
268  const Fw::StringBase& file,
269  U32 line,
270  U32 arg1,
271  U32 arg2,
272  U32 arg3,
273  U32 arg4,
274  U32 arg5
275  ) const;
276 
281  const Fw::StringBase& file,
282  U32 line,
283  U32 arg1,
284  U32 arg2,
285  U32 arg3,
286  U32 arg4,
287  U32 arg5,
288  U32 arg6
289  ) const;
290 
295  const Fw::StringBase& file,
296  U32 line,
297  U32 numArgs
298  ) const;
299 
300  PROTECTED:
301 
302  // ----------------------------------------------------------------------
303  // Time
304  // ----------------------------------------------------------------------
305 
309  Fw::Time getTime() const;
310 
311  PRIVATE:
312 
313  // ----------------------------------------------------------------------
314  // Special output ports
315  // ----------------------------------------------------------------------
316 
318  Fw::OutputLogPort m_Log_OutputPort[NUM_LOG_OUTPUT_PORTS];
319 
320 #if FW_ENABLE_TEXT_LOGGING == 1
321 
323  Fw::OutputLogTextPort m_LogText_OutputPort[NUM_LOGTEXT_OUTPUT_PORTS];
324 
325 #endif
326 
328  Fw::OutputTimePort m_Time_OutputPort[NUM_TIME_OUTPUT_PORTS];
329 
330  };
331 
332 }
333 
334 #endif
void log_FATAL_AF_UNEXPECTED_ASSERT(const Fw::StringBase &file, U32 line, U32 numArgs) const
void log_FATAL_AF_ASSERT_1(const Fw::StringBase &file, U32 line, U32 arg1) const
Definition: Time.hpp:9
friend class AssertFatalAdapterTesterBase
Friend class tester to support autocoded test harness.
void log_FATAL_AF_ASSERT_3(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3) const
I32 FwEnumStoreType
AssertFatalAdapterComponentBase(const char *compName="")
Construct AssertFatalAdapterComponentBase object.
friend class AssertFatalAdapterTester
Friend class tester implementation to support white-box testing.
void log_FATAL_AF_ASSERT_2(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2) const
void init()
Object initializer.
Definition: ObjBase.cpp:26
void log_FATAL_AF_ASSERT_5(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3, U32 arg4, U32 arg5) const
void set_Log_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to Log[portNum].
void log_FATAL_AF_ASSERT_4(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3, U32 arg4) const
void log_FATAL_AF_ASSERT_0(const Fw::StringBase &file, U32 line) const
void set_Time_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to Time[portNum].
virtual ~AssertFatalAdapterComponentBase()
Destroy AssertFatalAdapterComponentBase object.
PlatformIndexType FwIndexType
RateGroupDivider component implementation.
Auto-generated base for AssertFatalAdapter component.
void log_FATAL_AF_ASSERT_6(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3, U32 arg4, U32 arg5, U32 arg6) const