F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
CmdArgBuffer.hpp
Go to the documentation of this file.
1 /*
2  *
3  *
4  * Created on: March 1, 2014
5  * Author: T. Canham
6  */
7 
8 /*
9  * Description:
10  * This object contains the CmdARgBuffer type, used for holding the serialized arguments of commands
11  */
12 #ifndef FW_CMD_ARG_BUFFER_HPP
13 #define FW_CMD_ARG_BUFFER_HPP
14 
15 #include <Fw/FPrimeBasicTypes.hpp>
16 #include <Fw/Types/SerIds.hpp>
18 
19 namespace Fw {
20 
21 class CmdArgBuffer final : public SerializeBufferBase {
22  public:
23  enum {
26  };
27 
28  CmdArgBuffer(const U8* args, FwSizeType size);
29  CmdArgBuffer();
30  CmdArgBuffer(const CmdArgBuffer& other);
31  virtual ~CmdArgBuffer();
32  CmdArgBuffer& operator=(const CmdArgBuffer& other);
33 
34  DEPRECATED(FwSizeType getBuffCapacity() const, "Use getCapacity() instead");
35  FwSizeType getCapacity() const;
36 
37  U8* getBuffAddr();
38  const U8* getBuffAddr() const;
39 
40  private:
41  U8 m_bufferData[FW_CMD_ARG_BUFFER_MAX_SIZE];
42 };
43 
44 } // namespace Fw
45 
46 #endif
PlatformSizeType FwSizeType
virtual ~CmdArgBuffer()
destructor
type id for CmdArgBuffer
size when serialized. Buffer + size of buffer
U8 * getBuffAddr()
return address of buffer (non const version)
FwSizeType getCapacity() const
return capacity of buffer (how much it can hold)
DEPRECATED(FwSizeType getBuffCapacity() const, "Use getCapacity() instead")
Definitions for ISF type serial IDs.
uint8_t U8
8-bit unsigned integer
Definition: BasicTypes.h:53
CmdArgBuffer()
default constructor
CmdArgBuffer & operator=(const CmdArgBuffer &other)
Equal operator.
Command Buffer type id.
Definition: SerIds.hpp:45
Implementation of malloc based allocator.