F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
FatalHandlerComponentAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title FatalHandlerComponentAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for FatalHandler component base class
5 // ======================================================================
6 
7 #ifndef Svc_FatalHandlerComponentAc_HPP
8 #define Svc_FatalHandlerComponentAc_HPP
9 
11 #include "Fw/FPrimeBasicTypes.hpp"
12 #if !FW_DIRECT_PORT_CALLS
14 #endif
15 #if !FW_DIRECT_PORT_CALLS
17 #endif
19 
20 namespace Svc {
21 
28  {
29 
30  // ----------------------------------------------------------------------
31  // Friend classes
32  // ----------------------------------------------------------------------
33 
35  friend class FatalHandlerTesterBase;
37  friend class FatalHandlerTester;
38 
39  protected:
40 
41  // ----------------------------------------------------------------------
42  // Constants
43  // ----------------------------------------------------------------------
44 
46  enum {
48  };
49 
50  public:
51 
52  // ----------------------------------------------------------------------
53  // Component initialization
54  // ----------------------------------------------------------------------
55 
57  void init(
58  FwEnumStoreType instance = 0
59  );
60 
61 #if !FW_DIRECT_PORT_CALLS
62 
63  public:
64 
65  // ----------------------------------------------------------------------
66  // Getters for typed input ports
67  // ----------------------------------------------------------------------
68 
73  FwIndexType portNum
74  );
75 
76 #endif
77 
78  protected:
79 
80  // ----------------------------------------------------------------------
81  // Component construction and destruction
82  // ----------------------------------------------------------------------
83 
86  const char* compName = ""
87  );
88 
91 
92  protected:
93 
94  // ----------------------------------------------------------------------
95  // Getters for numbers of typed input ports
96  // ----------------------------------------------------------------------
97 
103  }
104 
105  protected:
106 
107  // ----------------------------------------------------------------------
108  // Handlers to implement for typed input ports
109  // ----------------------------------------------------------------------
110 
112  virtual void FatalReceive_handler(
113  FwIndexType portNum,
114  FwEventIdType Id
115  ) = 0;
116 
117 #if FW_DIRECT_PORT_CALLS
118  public:
119 #else
120  protected:
121 #endif
122 
123  // ----------------------------------------------------------------------
124  // Port handler base-class functions for typed input ports
125  //
126  // Call these functions directly to bypass the corresponding ports
127  // ----------------------------------------------------------------------
128 
131  FwIndexType portNum,
132  FwEventIdType Id
133  );
134 
135  private:
136 
137  // ----------------------------------------------------------------------
138  // Calls for messages received on typed input ports
139  // ----------------------------------------------------------------------
140 
142  static void m_p_FatalReceive_in(
143  Fw::PassiveComponentBase* callComp,
144  FwIndexType portNum,
145  FwEventIdType Id
146  );
147 
148 #if !FW_DIRECT_PORT_CALLS
149 
150  private:
151 
152  // ----------------------------------------------------------------------
153  // Typed input ports
154  // ----------------------------------------------------------------------
155 
157  Svc::InputFatalEventPort m_FatalReceive_InputPort[NUM_FATALRECEIVE_INPUT_PORTS];
158 
159 #endif
160 
161  };
162 
163 }
164 
165 #endif
virtual ~FatalHandlerComponentBase()
Destroy FatalHandlerComponentBase object.
Svc::InputFatalEventPort * get_FatalReceive_InputPort(FwIndexType portNum)
I32 FwEnumStoreType
static constexpr FwIndexType getNum_FatalReceive_InputPorts()
void init()
Object initializer.
Definition: ObjBase.cpp:24
FwIdType FwEventIdType
The type of an event identifier.
Auto-generated base for FatalHandler component.
friend class FatalHandlerTester
Friend class tester implementation to support white-box testing.
PlatformIndexType FwIndexType
RateGroupDivider component implementation.
virtual void FatalReceive_handler(FwIndexType portNum, FwEventIdType Id)=0
Handler for input port FatalReceive.
FatalHandlerComponentBase(const char *compName="")
Construct FatalHandlerComponentBase object.
void FatalReceive_handlerBase(FwIndexType portNum, FwEventIdType Id)
Handler base-class function for input port FatalReceive.
friend class FatalHandlerTesterBase
Friend class tester to support autocoded test harness.