10 #if FW_ENABLE_TEXT_LOGGING
32 this->m_portIn_InputPort[port].
init();
37 this->m_portIn_InputPort[port].
setPortNum(port);
39 #if FW_OBJECT_NAMES == 1
43 this->m_objName.toChar(),
46 this->m_portIn_InputPort[port].setObjName(portName.
toChar());
56 this->m_Log_OutputPort[port].
init();
58 #if FW_OBJECT_NAMES == 1
62 this->m_objName.toChar(),
65 this->m_Log_OutputPort[port].setObjName(portName.
toChar());
69 #if FW_ENABLE_TEXT_LOGGING == 1
73 port < static_cast<FwIndexType>(this->getNum_LogText_OutputPorts());
76 this->m_LogText_OutputPort[port].
init();
78 #if FW_OBJECT_NAMES == 1
82 this->m_objName.toChar(),
85 this->m_LogText_OutputPort[port].setObjName(portName.
toChar());
96 this->m_Time_OutputPort[port].
init();
98 #if FW_OBJECT_NAMES == 1
102 this->m_objName.toChar(),
105 this->m_Time_OutputPort[port].setObjName(portName.
toChar());
115 this->m_allocate_OutputPort[port].
init();
117 #if FW_OBJECT_NAMES == 1
121 this->m_objName.toChar(),
124 this->m_allocate_OutputPort[port].setObjName(portName.
toChar());
134 this->m_deallocate_OutputPort[port].
init();
136 #if FW_OBJECT_NAMES == 1
140 this->m_objName.toChar(),
143 this->m_deallocate_OutputPort[port].setObjName(portName.
toChar());
153 this->m_portOut_OutputPort[port].
init();
155 #if FW_OBJECT_NAMES == 1
159 this->m_objName.toChar(),
162 this->m_portOut_OutputPort[port].setObjName(portName.
toChar());
179 return &this->m_portIn_InputPort[portNum];
200 #if FW_ENABLE_TEXT_LOGGING == 1
202 void BufferRepeaterComponentBase ::
203 set_LogText_OutputPort(
209 portNum < this->getNum_LogText_OutputPorts(),
213 this->m_LogText_OutputPort[portNum].addCallPort(port);
229 this->m_Time_OutputPort[portNum].
addCallPort(port);
247 this->m_allocate_OutputPort[portNum].
addCallPort(port);
261 this->m_deallocate_OutputPort[portNum].
addCallPort(port);
275 this->m_portOut_OutputPort[portNum].
addCallPort(port);
278 #if FW_PORT_SERIALIZATION
287 Fw::InputSerializePort* port
295 this->m_Log_OutputPort[portNum].registerSerialPort(port);
298 #if FW_ENABLE_TEXT_LOGGING == 1
300 void BufferRepeaterComponentBase ::
301 set_LogText_OutputPort(
303 Fw::InputSerializePort* port
307 portNum < this->getNum_LogText_OutputPorts(),
311 this->m_LogText_OutputPort[portNum].registerSerialPort(port);
319 Fw::InputSerializePort* port
327 this->m_Time_OutputPort[portNum].registerSerialPort(port);
332 #if FW_PORT_SERIALIZATION
341 Fw::InputSerializePort* port
349 this->m_deallocate_OutputPort[portNum].registerSerialPort(port);
355 Fw::InputSerializePort* port
363 this->m_portOut_OutputPort[portNum].registerSerialPort(port);
374 Fw::PassiveComponentBase(compName)
405 #if FW_ENABLE_TEXT_LOGGING == 1
408 getNum_LogText_OutputPorts()
const
455 return this->m_Log_OutputPort[portNum].
isConnected();
458 #if FW_ENABLE_TEXT_LOGGING == 1
460 bool BufferRepeaterComponentBase ::
461 isConnected_LogText_OutputPort(
FwIndexType portNum)
464 portNum < this->getNum_LogText_OutputPorts(),
468 return this->m_LogText_OutputPort[portNum].isConnected();
481 return this->m_Time_OutputPort[portNum].
isConnected();
496 return this->m_allocate_OutputPort[portNum].
isConnected();
507 return this->m_deallocate_OutputPort[portNum].
isConnected();
518 return this->m_portOut_OutputPort[portNum].
isConnected();
560 return this->m_allocate_OutputPort[portNum].
invoke(
575 this->m_deallocate_OutputPort[portNum].
invoke(
590 this->m_portOut_OutputPort[portNum].
invoke(
607 if (this->m_Time_OutputPort[0].isConnected()) {
608 this->m_Time_OutputPort[0].
invoke(_logTime);
616 if (this->m_Log_OutputPort[0].isConnected()) {
620 #if FW_AMPCS_COMPATIBLE
629 #if FW_AMPCS_COMPATIBLE
632 static_cast<U8>(
sizeof(I32))
645 #if FW_AMPCS_COMPATIBLE
648 static_cast<U8>(
sizeof(U32))
661 this->m_Log_OutputPort[0].
invoke(
670 #if FW_ENABLE_TEXT_LOGGING
671 if (this->m_LogText_OutputPort[0].isConnected()) {
672 #if FW_OBJECT_NAMES == 1
673 const char* _formatString =
674 "(%s) %s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
676 const char* _formatString =
677 "%s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
684 this->m_objName.toChar(),
686 "AllocationSoftFailure ",
691 this->m_LogText_OutputPort[0].invoke(
709 if (this->m_Time_OutputPort[0].isConnected()) {
710 this->m_Time_OutputPort[0].
invoke(_logTime);
718 if (this->m_Log_OutputPort[0].isConnected()) {
722 #if FW_AMPCS_COMPATIBLE
724 _status = _logBuff.
serialize(
static_cast<U8>(2 + 1));
737 _status = _logBuff.
serialize(
static_cast<U32
>(0));
744 #if FW_AMPCS_COMPATIBLE
747 static_cast<U8>(
sizeof(I32))
760 #if FW_AMPCS_COMPATIBLE
763 static_cast<U8>(
sizeof(U32))
776 this->m_Log_OutputPort[0].
invoke(
785 #if FW_ENABLE_TEXT_LOGGING
786 if (this->m_LogText_OutputPort[0].isConnected()) {
787 #if FW_OBJECT_NAMES == 1
788 const char* _formatString =
789 "(%s) %s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
791 const char* _formatString =
792 "%s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
799 this->m_objName.toChar(),
801 "AllocationHardFailure ",
806 this->m_LogText_OutputPort[0].invoke(
823 if (this->m_Time_OutputPort[0].isConnected()) {
825 this->m_Time_OutputPort[0].
invoke(_time);
837 void BufferRepeaterComponentBase ::
uint8_t U8
8-bit unsigned integer
#define FW_NUM_ARRAY_ELEMENTS(a)
number of elements in an array
#define PRI_PlatformIntType
@ TB_NONE
No time base has been established.
PlatformAssertArgType FwAssertArgType
PlatformIndexType FwIndexType
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects)
@ WARNING_HI
A serious but recoverable event.
@ FATAL
A fatal non-recoverable event.
void init()
Object initializer.
const char * toChar() const
void init()
Initialization function.
void addCallPort(InputBufferGetPort *callPort)
Register an input port.
Fw::Buffer invoke(U32 size)
Invoke a port interface.
void addCallPort(InputBufferSendPort *callPort)
Register an input port.
void invoke(Fw::Buffer &fwBuffer)
Invoke a port interface.
void init()
Initialization function.
void init()
Initialization function.
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args)
Invoke a port interface.
void addCallPort(InputLogPort *callPort)
Register an input port.
void addCallPort(InputTimePort *callPort)
Register an input port.
void invoke(Fw::Time &time)
Invoke a port interface.
void init()
Initialization function.
SerializeStatus serialize(U8 val)
serialize 8-bit unsigned int
void format(const CHAR *formatString,...)
write formatted string to buffer
Auto-generated base for BufferRepeater component.
FwIndexType getNum_portOut_OutputPorts() const
void log_WARNING_HI_AllocationSoftFailure(I32 port, U32 size)
FwIndexType getNum_Time_OutputPorts() const
@ EVENTID_ALLOCATIONHARDFAILURE
Hard failure in allocation.
@ EVENTID_ALLOCATIONSOFTFAILURE
Soft failure in allocation.
bool isConnected_deallocate_OutputPort(FwIndexType portNum)
virtual ~BufferRepeaterComponentBase()
Destroy BufferRepeaterComponentBase object.
void set_deallocate_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to deallocate[portNum].
bool isConnected_allocate_OutputPort(FwIndexType portNum)
BufferRepeaterComponentBase(const char *compName="")
Construct BufferRepeaterComponentBase object.
Fw::Buffer allocate_out(FwIndexType portNum, U32 size)
Invoke output port allocate.
bool isConnected_portOut_OutputPort(FwIndexType portNum)
void set_Log_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to Log[portNum].
FwIndexType getNum_Log_OutputPorts() const
void set_allocate_OutputPort(FwIndexType portNum, Fw::InputBufferGetPort *port)
Connect port to allocate[portNum].
Fw::InputBufferSendPort * get_portIn_InputPort(FwIndexType portNum)
void log_FATAL_AllocationHardFailure(I32 port, U32 size)
FwIndexType getNum_deallocate_OutputPorts() const
FwIndexType getNum_allocate_OutputPorts() const
virtual void portIn_handler(FwIndexType portNum, Fw::Buffer &fwBuffer)=0
Handler for input port portIn.
bool isConnected_Log_OutputPort(FwIndexType portNum)
void deallocate_out(FwIndexType portNum, Fw::Buffer &fwBuffer)
Invoke output port deallocate.
void portOut_out(FwIndexType portNum, Fw::Buffer &fwBuffer)
Invoke output port portOut.
FwIndexType getNum_portIn_InputPorts() const
void set_Time_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to Time[portNum].
void portIn_handlerBase(FwIndexType portNum, Fw::Buffer &fwBuffer)
Handler base-class function for input port portIn.
bool isConnected_Time_OutputPort(FwIndexType portNum)
void set_portOut_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to portOut[portNum].
SerializeStatus
forward declaration for string
@ FW_SERIALIZE_OK
Serialization/Deserialization operation was successful.