F´ Flight Software - C/C++ Documentation  NASA-v1.5.0
A framework for building embedded system applications to NASA flight quality standards.
OutputSerializePort.cpp
Go to the documentation of this file.
2 #include <Fw/Types/Assert.hpp>
3 #include <stdio.h>
4 
5 #if FW_PORT_SERIALIZATION
6 
7 namespace Fw {
8 
9  // SerializePort has no call interface. It is to pass through serialized data
10 
11  OutputSerializePort::OutputSerializePort() : OutputPortBase() {
12  }
13 
14  OutputSerializePort::~OutputSerializePort() {
15  }
16 
17  void OutputSerializePort::init(void) {
19  }
20 
21 #if FW_OBJECT_TO_STRING == 1
22  void OutputSerializePort::toString(char* buffer, NATIVE_INT_TYPE size) {
23 #if FW_OBJECT_NAMES == 1
24  (void)snprintf(buffer, size, "Output Serial Port: %s %s->(%s)", this->m_objName, this->isConnected() ? "C" : "NC",
25  this->isConnected() ? this->m_connObj->getObjName() : "None");
26  buffer[size-1] = 0;
27 #else
28  (void)snprintf(buffer,size,"%s","OutputSerializePort");
29 #endif
30  }
31 #endif
32 
33 
34 }
35 
36 #endif // FW_PORT_SERIALIZATION
Fw::OutputPortBase::init
virtual void init(void)
Definition: OutputPortBase.cpp:23
Assert.hpp
NATIVE_INT_TYPE
int NATIVE_INT_TYPE
native integer type declaration
Definition: BasicTypes.hpp:29
OutputSerializePort.hpp
Fw
Definition: BufferGetPortAc.cpp:6