F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
TaskStatusEnumAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title TaskStatusEnumAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for TaskStatus enum
5 // ======================================================================
6 
7 #ifndef Os_TaskStatusEnumAc_HPP
8 #define Os_TaskStatusEnumAc_HPP
9 
10 #include "Fw/FPrimeBasicTypes.hpp"
12 #include "Fw/Types/String.hpp"
13 
14 namespace Os {
15 
17  class TaskStatus :
18  public Fw::Serializable
19  {
20 
21  public:
22 
23  // ----------------------------------------------------------------------
24  // Types
25  // ----------------------------------------------------------------------
26 
28  typedef U8 SerialType;
29 
31  enum T {
33  OP_OK = 0,
56  };
57 
59  typedef T t;
60 
61  public:
62 
63  // ----------------------------------------------------------------------
64  // Constants
65  // ----------------------------------------------------------------------
66 
67  enum {
72  };
73 
74  public:
75 
76  // ----------------------------------------------------------------------
77  // Constructors
78  // ----------------------------------------------------------------------
79 
82  {
83  this->e = OP_OK;
84  }
85 
88  const T e1
89  )
90  {
91  this->e = e1;
92  }
93 
96  const TaskStatus& obj
97  )
98  {
99  this->e = obj.e;
100  }
101 
102  public:
103 
104  // ----------------------------------------------------------------------
105  // Operators
106  // ----------------------------------------------------------------------
107 
110  const TaskStatus& obj
111  );
112 
115  T e1
116  );
117 
119  operator T() const
120  {
121  return this->e;
122  }
123 
125  bool operator==(T e1) const
126  {
127  return this->e == e1;
128  }
129 
131  bool operator!=(T e1) const
132  {
133  return !(*this == e1);
134  }
135 
136 #ifdef BUILD_UT
137 
139  friend std::ostream& operator<<(
140  std::ostream& os,
141  const TaskStatus& obj
142  );
143 
144 #endif
145 
146  public:
147 
148  // ----------------------------------------------------------------------
149  // Member functions
150  // ----------------------------------------------------------------------
151 
153  bool isValid() const;
154 
157  Fw::SerialBufferBase& buffer,
159  ) const;
160 
163  Fw::SerialBufferBase& buffer,
165  );
166 
167 #if FW_SERIALIZABLE_TO_STRING
168 
170  void toString(
171  Fw::StringBase& sb
172  ) const;
173 
174 #endif
175 
176  public:
177 
178  // ----------------------------------------------------------------------
179  // Member variables
180  // ----------------------------------------------------------------------
181 
183  T e;
184 
185  };
186 
187 }
188 
189 #endif
bool isValid() const
Check raw enum value for validity.
Task feature is not supported.
U8 SerialType
The serial representation type.
error trying to join the task
The number of enumerated constants.
started with invalid stack size
SerializeStatus
forward declaration for string
T
The raw enum type.
TaskStatus(const T e1)
Constructor (user-provided value)
FPP shadow-enum representing Os::Task::Status.
started task with invalid parameters
Fw::SerializeStatus serializeTo(Fw::SerialBufferBase &buffer, Fw::Endianness mode=Fw::Endianness::BIG) const
Serialize raw enum value to SerialType.
error trying to delay the task
T t
For backwards compatibility.
unable to set the task affinity
T e
The raw enum value.
permissions error setting-up tasks
bool operator!=(T e1) const
Inequality operator.
The size of the serial representation.
uint8_t U8
8-bit unsigned integer
Definition: BasicTypes.h:53
message sent/received okay
Task is in an invalid state for the operation.
TaskStatus & operator=(const TaskStatus &obj)
Copy assignment operator (object)
Endianness
TaskStatus(const TaskStatus &obj)
Copy constructor.
Fw::SerializeStatus deserializeFrom(Fw::SerialBufferBase &buffer, Fw::Endianness mode=Fw::Endianness::BIG)
Deserialize raw enum value from SerialType.
bool operator==(T e1) const
Equality operator.
TaskStatus()
Constructor (default value of OP_OK)
unexpected error return value
unable to allocate more tasks
Big endian serialization.