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 42 "%s_portIn_InputPort[%" PRI_PlatformIntType
"]",
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 61 "%s_Log_OutputPort[%" PRI_PlatformIntType
"]",
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 81 "%s_LogText_OutputPort[%" PRI_PlatformIntType
"]",
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 101 "%s_Time_OutputPort[%" PRI_PlatformIntType
"]",
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 120 "%s_allocate_OutputPort[%" PRI_PlatformIntType
"]",
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 139 "%s_deallocate_OutputPort[%" PRI_PlatformIntType
"]",
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 158 "%s_portOut_OutputPort[%" PRI_PlatformIntType
"]",
159 this->m_objName.toChar(),
162 this->m_portOut_OutputPort[port].setObjName(portName.
toChar());
176 static_cast<FwAssertArgType>(portNum)
179 return &this->m_portIn_InputPort[portNum];
194 static_cast<FwAssertArgType>(portNum)
200 #if FW_ENABLE_TEXT_LOGGING == 1 202 void BufferRepeaterComponentBase ::
203 set_LogText_OutputPort(
209 portNum < this->getNum_LogText_OutputPorts(),
210 static_cast<FwAssertArgType>(portNum)
213 this->m_LogText_OutputPort[portNum].addCallPort(port);
226 static_cast<FwAssertArgType>(portNum)
229 this->m_Time_OutputPort[portNum].
addCallPort(port);
244 static_cast<FwAssertArgType>(portNum)
247 this->m_allocate_OutputPort[portNum].
addCallPort(port);
258 static_cast<FwAssertArgType>(portNum)
261 this->m_deallocate_OutputPort[portNum].
addCallPort(port);
272 static_cast<FwAssertArgType>(portNum)
275 this->m_portOut_OutputPort[portNum].
addCallPort(port);
278 #if FW_PORT_SERIALIZATION 287 Fw::InputSerializePort* port
292 static_cast<FwAssertArgType>(portNum)
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(),
308 static_cast<FwAssertArgType>(portNum)
311 this->m_LogText_OutputPort[portNum].registerSerialPort(port);
319 Fw::InputSerializePort* port
324 static_cast<FwAssertArgType>(portNum)
327 this->m_Time_OutputPort[portNum].registerSerialPort(port);
332 #if FW_PORT_SERIALIZATION 341 Fw::InputSerializePort* port
346 static_cast<FwAssertArgType>(portNum)
349 this->m_deallocate_OutputPort[portNum].registerSerialPort(port);
355 Fw::InputSerializePort* port
360 static_cast<FwAssertArgType>(portNum)
363 this->m_portOut_OutputPort[portNum].registerSerialPort(port);
374 Fw::PassiveComponentBase(compName)
405 #if FW_ENABLE_TEXT_LOGGING == 1 408 getNum_LogText_OutputPorts()
const 452 static_cast<FwAssertArgType>(portNum)
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(),
465 static_cast<FwAssertArgType>(portNum)
468 return this->m_LogText_OutputPort[portNum].isConnected();
478 static_cast<FwAssertArgType>(portNum)
481 return this->m_Time_OutputPort[portNum].
isConnected();
493 static_cast<FwAssertArgType>(portNum)
496 return this->m_allocate_OutputPort[portNum].
isConnected();
504 static_cast<FwAssertArgType>(portNum)
507 return this->m_deallocate_OutputPort[portNum].
isConnected();
515 static_cast<FwAssertArgType>(portNum)
518 return this->m_portOut_OutputPort[portNum].
isConnected();
536 static_cast<FwAssertArgType>(portNum)
558 static_cast<FwAssertArgType>(portNum)
562 this->m_allocate_OutputPort[portNum].isConnected(),
563 static_cast<FwAssertArgType>(portNum)
565 return this->m_allocate_OutputPort[portNum].
invoke(
578 static_cast<FwAssertArgType>(portNum)
582 this->m_deallocate_OutputPort[portNum].isConnected(),
583 static_cast<FwAssertArgType>(portNum)
585 this->m_deallocate_OutputPort[portNum].
invoke(
598 static_cast<FwAssertArgType>(portNum)
602 this->m_portOut_OutputPort[portNum].isConnected(),
603 static_cast<FwAssertArgType>(portNum)
605 this->m_portOut_OutputPort[portNum].
invoke(
622 if (this->m_Time_OutputPort[0].isConnected()) {
623 this->m_Time_OutputPort[0].
invoke(_logTime);
631 if (this->m_Log_OutputPort[0].isConnected()) {
635 #if FW_AMPCS_COMPATIBLE 637 _status = _logBuff.
serialize(static_cast<U8>(2));
640 static_cast<FwAssertArgType>(_status)
644 #if FW_AMPCS_COMPATIBLE 647 static_cast<U8>(
sizeof(I32))
651 static_cast<FwAssertArgType>(_status)
657 static_cast<FwAssertArgType>(_status)
660 #if FW_AMPCS_COMPATIBLE 663 static_cast<U8>(
sizeof(U32))
667 static_cast<FwAssertArgType>(_status)
673 static_cast<FwAssertArgType>(_status)
676 this->m_Log_OutputPort[0].
invoke(
685 #if FW_ENABLE_TEXT_LOGGING 686 if (this->m_LogText_OutputPort[0].isConnected()) {
687 #if FW_OBJECT_NAMES == 1 688 const char* _formatString =
689 "(%s) %s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
691 const char* _formatString =
692 "%s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
699 this->m_objName.toChar(),
701 "AllocationSoftFailure ",
706 this->m_LogText_OutputPort[0].invoke(
724 if (this->m_Time_OutputPort[0].isConnected()) {
725 this->m_Time_OutputPort[0].
invoke(_logTime);
733 if (this->m_Log_OutputPort[0].isConnected()) {
737 #if FW_AMPCS_COMPATIBLE 739 _status = _logBuff.
serialize(static_cast<U8>(2 + 1));
742 static_cast<FwAssertArgType>(_status)
746 _status = _logBuff.
serialize(static_cast<U8>(4));
749 static_cast<FwAssertArgType>(_status)
752 _status = _logBuff.
serialize(static_cast<U32>(0));
755 static_cast<FwAssertArgType>(_status)
759 #if FW_AMPCS_COMPATIBLE 762 static_cast<U8>(
sizeof(I32))
766 static_cast<FwAssertArgType>(_status)
772 static_cast<FwAssertArgType>(_status)
775 #if FW_AMPCS_COMPATIBLE 778 static_cast<U8>(
sizeof(U32))
782 static_cast<FwAssertArgType>(_status)
788 static_cast<FwAssertArgType>(_status)
791 this->m_Log_OutputPort[0].
invoke(
800 #if FW_ENABLE_TEXT_LOGGING 801 if (this->m_LogText_OutputPort[0].isConnected()) {
802 #if FW_OBJECT_NAMES == 1 803 const char* _formatString =
804 "(%s) %s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
806 const char* _formatString =
807 "%s: Failed to allocate %" PRIi32
" byte buffer for port %" PRIu32
"";
814 this->m_objName.toChar(),
816 "AllocationHardFailure ",
821 this->m_LogText_OutputPort[0].invoke(
838 if (this->m_Time_OutputPort[0].isConnected()) {
840 this->m_Time_OutputPort[0].
invoke(_time);
852 void BufferRepeaterComponentBase ::
Serialization/Deserialization operation was successful.
FwIndexType getNum_allocate_OutputPorts() const
void addCallPort(InputTimePort *callPort)
Register an input port.
Soft failure in allocation.
SerializeStatus serialize(U8 val)
serialize 8-bit unsigned int
Fw::Buffer invoke(U32 size) const
Invoke a port interface.
FwIndexType getNum_portOut_OutputPorts() const
FwIndexType getNum_deallocate_OutputPorts() const
bool isConnected_deallocate_OutputPort(FwIndexType portNum)
void set_Time_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to Time[portNum].
void portOut_out(FwIndexType portNum, Fw::Buffer &fwBuffer)
Invoke output port portOut.
FwIndexType getNum_Time_OutputPorts() const
PlatformIndexType FwIndexType
void init()
Object initializer.
bool isConnected_allocate_OutputPort(FwIndexType portNum)
SerializeStatus
forward declaration for string
void addCallPort(InputBufferGetPort *callPort)
Register an input port.
BufferRepeaterComponentBase(const char *compName="")
Construct BufferRepeaterComponentBase object.
virtual void portIn_handler(FwIndexType portNum, Fw::Buffer &fwBuffer)=0
Handler for input port portIn.
void init()
Initialization function.
void invoke(Fw::Buffer &fwBuffer) const
Invoke a port interface.
void addCallPort(InputBufferSendPort *callPort)
Register an input port.
void set_portOut_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to portOut[portNum].
void invoke(Fw::Time &time) const
Invoke a port interface.
bool isConnected_Time_OutputPort(FwIndexType portNum)
const char * toChar() const
No time base has been established.
bool isConnected_Log_OutputPort(FwIndexType portNum)
Fw::Buffer allocate_out(FwIndexType portNum, U32 size)
Invoke output port allocate.
A serious but recoverable event.
Fw::InputBufferSendPort * get_portIn_InputPort(FwIndexType portNum)
virtual ~BufferRepeaterComponentBase()
Destroy BufferRepeaterComponentBase object.
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
void init()
Initialization function.
void set_Log_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to Log[portNum].
void portIn_handlerBase(FwIndexType portNum, Fw::Buffer &fwBuffer)
Handler base-class function for input port portIn.
bool isConnected_portOut_OutputPort(FwIndexType portNum)
Hard failure in allocation.
FwIndexType getNum_portIn_InputPorts() const
void init()
Initialization function.
void set_deallocate_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to deallocate[portNum].
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port interface.
A fatal non-recoverable event.
#define FW_NUM_ARRAY_ELEMENTS(a)
number of elements in an array
void addCallPort(InputLogPort *callPort)
Register an input port.
void init()
Initialization function.
void log_FATAL_AllocationHardFailure(I32 port, U32 size) const
void log_WARNING_HI_AllocationSoftFailure(I32 port, U32 size) const
Auto-generated base for BufferRepeater component.
void set_allocate_OutputPort(FwIndexType portNum, Fw::InputBufferGetPort *port)
Connect port to allocate[portNum].
FwIndexType getNum_Log_OutputPorts() const
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects) ...
void deallocate_out(FwIndexType portNum, Fw::Buffer &fwBuffer)
Invoke output port deallocate.