F´ Flight Software - C/C++ Documentation  devel
A framework for building embedded system applications to NASA flight quality standards.
String.hpp
Go to the documentation of this file.
1 #ifndef FW_FIXED_LENGTH_STRING_TYPE_HPP
2 #define FW_FIXED_LENGTH_STRING_TYPE_HPP
3 
4 #include <FpConfig.hpp>
6 #include <Fw/Cfg/SerIds.hpp>
7 
8 namespace Fw {
9 
10  class String : public Fw::StringBase {
11  public:
12 
13  enum {
17  };
18 
19  String(const char* src);
20  String(const StringBase& src);
21  String(const String& src);
22  String();
23  String& operator=(const String& other);
24  String& operator=(const StringBase& other);
25  String& operator=(const char* other);
26  ~String();
27 
28  const char* toChar() const;
29  NATIVE_UINT_TYPE getCapacity() const ;
30 
31  private:
32 
33  char m_buf[STRING_SIZE];
34  };
35 }
36 
37 #endif
PlatformUIntType NATIVE_UINT_TYPE
Definition: BasicTypes.h:52
#define FW_FIXED_LENGTH_STRING_SIZE
Character array size for the filepath character type.
Definition: FpConfig.h:344
U16 FwBuffSizeType
Definition: FpConfig.h:30
C++-compatible configuration header for fprime configuration.
Definitions for ISF type serial IDs.
Declares ISF string base class.
@ STRING_SIZE
Storage for string.
Definition: String.hpp:15
@ SERIALIZED_TYPE_ID
typeid for string type
Definition: String.hpp:14
@ SERIALIZED_SIZE
Serialized size is size of buffer + size field.
Definition: String.hpp:16
NATIVE_UINT_TYPE getCapacity() const
return buffer size
Definition: String.cpp:52
const char * toChar() const
gets char buffer
Definition: String.cpp:48
~String()
destructor
Definition: String.cpp:45
String & operator=(const String &other)
assignment operator
Definition: String.cpp:22
String()
default constructor
Definition: String.cpp:18
@ FW_TYPEID_FIXED_LENGTH_STRING
256 char string Buffer type id
Definition: SerIds.hpp:59