Compute Graph Framework SDK Reference  5.16
dw::framework::SimpleNode Class Reference

Detailed Description

Definition at line 86 of file SimpleNode.hpp.

Inheritance diagram for dw::framework::SimpleNode:
Collaboration diagram for dw::framework::SimpleNode:

Public Member Functions

dwStatus addToErrorSignal (uint32_t error, dwTime_t timestamp=0L) final
 
dwStatus addToHealthSignal (uint32_t error, dwTime_t timestamp=0L) override
 
dwStatus clearErrorSignal () override
 
dwStatus clearHealthSignal () override
 
dwStatus collectErrorSignals (dwGraphErrorSignal *&errorSignal, bool updateFromModule=true) override
 
dwStatus collectHealthSignals (dwGraphHealthSignal *&healthSignal, bool updateFromModule=false) override
 
dwStatus getInputChannel (const size_t portID, ChannelObject *&channel) const override
 Gets the input channel associated with the input port. More...
 
template<typename NodeT , size_t PortIndex>
ManagedPortInput< decltype(portType< NodeT, PortDirection::INPUT, PortIndex >())> & getInputPort ()
 Get a previously initialized non-array ManagedPortInput. More...
 
dwStatus getInputPort (const size_t portID, dw::framework::PortBase *&port) const override
 Gets the input port associated with the input port Id. More...
 
template<typename NodeT , size_t PortIndex>
ManagedPortInput< decltype(portType< NodeT, PortDirection::INPUT, PortIndex >())> & getInputPort (size_t arrayIndex)
 Get one specific ManagedPortInput from a previously initialized input array port. More...
 
uint32_t getIterationCount () const
 
dwStatus getModuleErrorSignal (dwErrorSignal &errorSignal) override
 
dwStatus getModuleHealthSignal (dwHealthSignal &healthSignal) override
 
dwStatus getName (const char **name) override
 
dwStatus getNodeErrorSignal (dwGraphErrorSignal &errorSignal) override
 
dwStatus getNodeHealthSignal (dwGraphHealthSignal &healthSignal) override
 
uint32_t getNodePeriod () const
 
dwStatus getOutputChannel (const size_t portID, ChannelObject *&channel) const override
 Gets the output channel associated with the output port. More...
 
template<typename NodeT , size_t PortIndex>
ManagedPortOutput< decltype(portType< NodeT, PortDirection::OUTPUT, PortIndex >())> & getOutputPort ()
 Get a previously initialized non-array ManagedPortOutput. More...
 
dwStatus getOutputPort (const size_t portID, dw::framework::PortBase *&port) const override
 Gets the output port associated with the output port Id. More...
 
template<typename NodeT , size_t PortIndex>
ManagedPortOutput< decltype(portType< NodeT, PortDirection::OUTPUT, PortIndex >())> & getOutputPort (size_t arrayIndex)
 Get one specific ManagedPortOutput from a previously initialized output array port. More...
 
dwStatus getPass (Pass **pass, size_t index) override
 
size_t getPassCount () const noexcept override
 
dwStatus getPasses (VectorFixed< Pass * > &passList) override
 
const dw::core::HeapHashMap< size_t, std::shared_ptr< ManagedPortInputBase > > & getRegisteredInputPorts () const
 
const dw::core::HeapHashMap< size_t, std::shared_ptr< ManagedPortOutputBase > > & getRegisteredOutputPorts () const
 
template<typename NodeT , size_t PortIndex, typename... Args>
void initInputArrayPort (size_t arrayIndex, Args &&... args)
 Initialize one ManagedPortInput of an array which will be owned by the base class and can be retrieved using getInputPort(size_t). More...
 
template<typename NodeT , size_t PortIndex, typename... Args>
void initInputArrayPorts (Args &&... args)
 Initialize an array of ManagedPortInput which will be owned by the base class and can be retrieved using getInputPort(size_t). More...
 
template<typename NodeT , size_t PortIndex, typename... Args>
void initInputPort (Args &&... args)
 Initialize a ManagedPortInput which will be owned by the base class and can be retrieved using getInputPort(). More...
 
template<typename NodeT , size_t PortIndex, typename... Args>
void initOutputArrayPort (size_t arrayIndex, Args &&... args)
 Initialize one ManagedPortOutput of an array which will be owned by the base class and can be retrieved using getOutputPort(size_t). More...
 
template<typename NodeT , size_t PortIndex, typename... Args>
void initOutputArrayPorts (Args &&... args)
 Initialize an array of ManagedPortOutput which will be owned by the base class and can be retrieved using getOutputPort(size_t). More...
 
template<typename NodeT , size_t PortIndex, typename... Args>
void initOutputPort (Args &&... args)
 Initialize a ManagedPortOutput which will be owned by the base class and can be retrieved using getOutputPort(). More...
 
template<typename Func >
void iterateManagedInputPorts (Func func)
 
template<typename Func >
void iterateManagedOutputPorts (Func func)
 
template<typename Func , typename PortList >
void iteratePorts (PortList &portList, Func func)
 
dwStatus reset () override
 
void resetPorts () override
 Default implementation to reset ports managed by the base class. More...
 
dwStatus run () override
 
dwStatus runPass (size_t passIndex) override
 
dwStatus setInputChannel (ChannelObject *channel, size_t portID) override
 Associate an input port with a channel instances. More...
 
dwStatus setIterationCount (uint32_t iterationCount) override
 
template<typename ModuleHandle_t >
dwStatus setModuleHandle (ModuleHandle_t handle, dwContextHandle_t context)
 
dwStatus setName (const char *name) final
 
dwStatus setNodePeriod (uint32_t period) override
 
virtual dwStatus setObjectHandle (dwModuleHandle_t handle)
 
dwStatus setOutputChannel (ChannelObject *channel, size_t portID) override
 Associate an output port with a channel instances. More...
 
dwStatus setState (const char *state) override
 
dwStatus setup ()
 Default implementation of the setup pass. More...
 
 SimpleNode (NodeAllocationParams params)
 Constructor which tailors the preallocated size of the internal collections for ports and passes to the need of the concrete node. More...
 
dwStatus teardown ()
 Default implementation of the teardown pass. More...
 
dwStatus updateCurrentErrorSignal (dwGraphErrorSignal &signal) override
 A function that allows user override to update error signal It is automatically called by dwFramework when getErrorSignal is called and when pass returns non-success return code. More...
 
dwStatus updateCurrentHealthSignal (dwGraphHealthSignal &signal) override
 A function that allows user override to update health signal It is automatically called by dwFramework during teardown and when pass returns non-success return code. More...
 
dwStatus updateHealthSignal (const dwGraphHealthSignal &signal)
 Adds the provided Health Signal to the Health Signal Array. If the array is full, the new signal will not be added. More...
 
dwStatus validate () override
 
dwStatus validate (const char *direction, const PortCollectionDescriptor &collection, dw::core::Function< bool(size_t)> isPortBound)
 Helper function used by dw::framework::SimpleNodeT::validate. More...
 
- Public Member Functions inherited from dw::framework::Node
virtual dwStatus addToErrorSignal (uint32_t error, dwTime_t timestamp=0L)=0
 A function the allows user to add an error to the error signal list. More...
 
virtual dwStatus addToHealthSignal (uint32_t error, dwTime_t timestamp=0L)=0
 A function the allows user to add an error to the health signal list. More...
 
virtual dwStatus clearErrorSignal ()=0
 Clear the error signal for this node. More...
 
virtual dwStatus clearHealthSignal ()=0
 Clear the health signal for this node. More...
 
virtual dwStatus collectErrorSignals (dwGraphErrorSignal *&errorSignal, bool updateFromModule=true)=0
 Collect error signals from node and module, combine and return the pointer to the error signal for this node. If combination of module and node signals exceeds max amount, will return up to max amount, node first, and DW_BUFFER_FULL. More...
 
virtual dwStatus collectHealthSignals (dwGraphHealthSignal *&healthSignal, bool updateFromModule=false)=0
 Collect health signals from node and module, combine and return the pointer to the health signal for this node. If combination of module and node signals exceeds max amount, will return up to max amount, node first, and DW_BUFFER_FULL. More...
 
virtual dwStatus getInputChannel (const size_t portID, ChannelObject *&channel) const =0
 Gets the input channel associated with the input port. More...
 
virtual dwStatus getInputPort (const size_t portID, dw::framework::PortBase *&port) const =0
 Gets the input port associated with the port id. More...
 
virtual dwStatus getModuleErrorSignal (dwErrorSignal &errorSignal)=0
 Get a copy of the error signals from the module that is a member of this node. More...
 
virtual dwStatus getModuleHealthSignal (dwHealthSignal &healthSignal)=0
 Return a copy of health signals from module that is a member of node. More...
 
virtual dwStatus getName (const char **name)=0
 Get the name of the node. More...
 
virtual dwStatus getNodeErrorSignal (dwGraphErrorSignal &errorSignal)=0
 Get a copy of the error signals for the node. More...
 
virtual dwStatus getNodeHealthSignal (dwGraphHealthSignal &healthSignal)=0
 Return a copy of graph health signals for the node. More...
 
virtual dwStatus getOutputChannel (const size_t portID, ChannelObject *&channel) const =0
 Gets the output channel associated with the output port. More...
 
virtual dwStatus getOutputPort (const size_t portID, dw::framework::PortBase *&port) const =0
 Gets the output port associated with the port id. More...
 
virtual dwStatus getPass (Pass **pass, size_t index)=0
 Get a const pointer to the pass at a specific index. More...
 
virtual size_t getPassCount () const noexcept=0
 Get number of passes in the node. More...
 
virtual dwStatus getPasses (VectorFixed< Pass * > &passList)=0
 Get all the passes in the node. More...
 
virtual dwStatus reset ()=0
 Resets the state of the node. More...
 
virtual void resetPorts ()=0
 Resets all the ports in the node. More...
 
virtual dwStatus run ()=0
 Runs all the passes in the node. More...
 
virtual dwStatus runPass (size_t passIndex)=0
 Run one pass by index as defined by the pass descriptors. More...
 
virtual dwStatus setInputChannel (ChannelObject *channel, size_t portID)=0
 Sets an input channel for this node with an accompanying port. More...
 
virtual dwStatus setIterationCount (uint32_t iterationCount)=0
 Sets the node's iteration count. More...
 
virtual dwStatus setName (const char *name)=0
 Set the name of the node. More...
 
virtual dwStatus setNodePeriod (uint32_t period)=0
 Set the node's period. More...
 
virtual dwStatus setOutputChannel (ChannelObject *channel, size_t portID)=0
 Sets an output channel for this node with an accompanying port. More...
 
virtual dwStatus setState (const char *state)=0
 Set the current state in node. Node implementation of this API need to be thread-safe. More...
 
virtual dwStatus updateCurrentErrorSignal (dwGraphErrorSignal &signal)=0
 A function that allows user override to update error signal It is automatically called by dwFramework when getErrorSignal is called and when pass returns non-success return code. More...
 
virtual dwStatus updateCurrentHealthSignal (dwGraphHealthSignal &signal)=0
 A function that allows user override to update health signal It is automatically called by dwFramework during teardown and when pass returns non-success return code. More...
 
virtual dwStatus validate ()=0
 Checks that all mandatory ports are bound. The implementation should validate that all the ports are bound to the appropriate channels (any required ports, that is). For example, a camera node may have processed output and raw output ports, but only one is required to be bound. More...
 
virtual ~Node ()=default
 

Protected Member Functions

dwGraphHealthSignalgetHealthSignal ()
 
dwStatus getModuleHandle (dwModuleHandle_t *moduleHandle, void *handle, dwContextHandle_t context)
 
template<typename NodeT , size_t PassIndex, typename PassFunctionT >
void registerPass (PassFunctionT func, cudaStream_t const cudaStream, std::initializer_list< std::pair< dwStatus, uint32_t > > const &returnMapping={})
 Register a GPU pass function and a cuda stream with the node base class. More...
 
template<typename NodeT , size_t PassIndex, typename PassFunctionT >
void registerPass (PassFunctionT func, std::initializer_list< std::pair< dwStatus, uint32_t > > const &returnMapping={})
 Register a pass function with the node base class. More...
 

Protected Attributes

std::atomic< bool > m_asyncResetFlag
 
dw::core::HeapHashMap< size_t, std::shared_ptr< ManagedPortInputBase > > m_inputPorts
 
dw::core::HeapHashMap< size_t, std::shared_ptr< ManagedPortOutputBase > > m_outputPorts
 

Additional Inherited Members

- Static Public Attributes inherited from dw::framework::Node
static constexpr const size_t MAX_NAME_LEN {128U}
 

Constructor & Destructor Documentation

◆ SimpleNode()

dw::framework::SimpleNode::SimpleNode ( NodeAllocationParams  params)

Constructor which tailors the preallocated size of the internal collections for ports and passes to the need of the concrete node.

Member Function Documentation

◆ addToErrorSignal()

dwStatus dw::framework::SimpleNode::addToErrorSignal ( uint32_t  error,
dwTime_t  timestamp = 0L 
)
finalvirtual

Implements dw::framework::Node.

◆ addToHealthSignal()

dwStatus dw::framework::SimpleNode::addToHealthSignal ( uint32_t  error,
dwTime_t  timestamp = 0L 
)
overridevirtual

Implements dw::framework::Node.

◆ clearErrorSignal()

dwStatus dw::framework::SimpleNode::clearErrorSignal ( )
overridevirtual

Implements dw::framework::Node.

◆ clearHealthSignal()

dwStatus dw::framework::SimpleNode::clearHealthSignal ( )
overridevirtual

Implements dw::framework::Node.

◆ collectErrorSignals()

dwStatus dw::framework::SimpleNode::collectErrorSignals ( dwGraphErrorSignal *&  errorSignal,
bool  updateFromModule = true 
)
overridevirtual

Implements dw::framework::Node.

◆ collectHealthSignals()

dwStatus dw::framework::SimpleNode::collectHealthSignals ( dwGraphHealthSignal *&  healthSignal,
bool  updateFromModule = false 
)
overridevirtual

Implements dw::framework::Node.

◆ getHealthSignal()

dwGraphHealthSignal & dw::framework::SimpleNode::getHealthSignal ( )
inlineprotected

Definition at line 286 of file SimpleNode.hpp.

◆ getInputChannel()

dwStatus dw::framework::SimpleNode::getInputChannel ( const size_t  portID,
ChannelObject *&  channel 
) const
overridevirtual

Gets the input channel associated with the input port.

Implements dw::framework::Node.

◆ getInputPort() [1/3]

template<typename NodeT , size_t PortIndex>
ManagedPortInput< decltype(portType< NodeT, PortDirection::INPUT, PortIndex >())> & dw::framework::SimpleNode::getInputPort ( )
inline

Get a previously initialized non-array ManagedPortInput.

Definition at line 423 of file SimpleNode.hpp.

References dw::framework::descriptorPortArray().

◆ getInputPort() [2/3]

dwStatus dw::framework::SimpleNode::getInputPort ( const size_t  portID,
dw::framework::PortBase *&  port 
) const
overridevirtual

Gets the input port associated with the input port Id.

Implements dw::framework::Node.

◆ getInputPort() [3/3]

template<typename NodeT , size_t PortIndex>
ManagedPortInput< decltype(portType< NodeT, PortDirection::INPUT, PortIndex >())> & dw::framework::SimpleNode::getInputPort ( size_t  arrayIndex)
inline

Get one specific ManagedPortInput from a previously initialized input array port.

Definition at line 446 of file SimpleNode.hpp.

◆ getIterationCount()

uint32_t dw::framework::SimpleNode::getIterationCount ( ) const

◆ getModuleErrorSignal()

dwStatus dw::framework::SimpleNode::getModuleErrorSignal ( dwErrorSignal &  errorSignal)
overridevirtual

Implements dw::framework::Node.

◆ getModuleHandle()

dwStatus dw::framework::SimpleNode::getModuleHandle ( dwModuleHandle_t *  moduleHandle,
void *  handle,
dwContextHandle_t  context 
)
protected

◆ getModuleHealthSignal()

dwStatus dw::framework::SimpleNode::getModuleHealthSignal ( dwHealthSignal &  healthSignal)
overridevirtual

Implements dw::framework::Node.

◆ getName()

dwStatus dw::framework::SimpleNode::getName ( const char **  name)
overridevirtual

Implements dw::framework::Node.

◆ getNodeErrorSignal()

dwStatus dw::framework::SimpleNode::getNodeErrorSignal ( dwGraphErrorSignal errorSignal)
overridevirtual

Implements dw::framework::Node.

◆ getNodeHealthSignal()

dwStatus dw::framework::SimpleNode::getNodeHealthSignal ( dwGraphHealthSignal healthSignal)
overridevirtual

Implements dw::framework::Node.

◆ getNodePeriod()

uint32_t dw::framework::SimpleNode::getNodePeriod ( ) const

◆ getOutputChannel()

dwStatus dw::framework::SimpleNode::getOutputChannel ( const size_t  portID,
ChannelObject *&  channel 
) const
overridevirtual

Gets the output channel associated with the output port.

Implements dw::framework::Node.

◆ getOutputPort() [1/3]

template<typename NodeT , size_t PortIndex>
ManagedPortOutput< decltype(portType< NodeT, PortDirection::OUTPUT, PortIndex >())> & dw::framework::SimpleNode::getOutputPort ( )
inline

Get a previously initialized non-array ManagedPortOutput.

Definition at line 473 of file SimpleNode.hpp.

References dw::framework::descriptorPortArray().

◆ getOutputPort() [2/3]

dwStatus dw::framework::SimpleNode::getOutputPort ( const size_t  portID,
dw::framework::PortBase *&  port 
) const
overridevirtual

Gets the output port associated with the output port Id.

Implements dw::framework::Node.

◆ getOutputPort() [3/3]

template<typename NodeT , size_t PortIndex>
ManagedPortOutput< decltype(portType< NodeT, PortDirection::OUTPUT, PortIndex >())> & dw::framework::SimpleNode::getOutputPort ( size_t  arrayIndex)
inline

Get one specific ManagedPortOutput from a previously initialized output array port.

Definition at line 496 of file SimpleNode.hpp.

◆ getPass()

dwStatus dw::framework::SimpleNode::getPass ( Pass **  pass,
size_t  index 
)
overridevirtual

Implements dw::framework::Node.

◆ getPassCount()

size_t dw::framework::SimpleNode::getPassCount ( ) const
overridevirtualnoexcept

Implements dw::framework::Node.

◆ getPasses()

dwStatus dw::framework::SimpleNode::getPasses ( VectorFixed< Pass * > &  passList)
overridevirtual

Implements dw::framework::Node.

◆ getRegisteredInputPorts()

const dw::core::HeapHashMap< size_t, std::shared_ptr< ManagedPortInputBase > > & dw::framework::SimpleNode::getRegisteredInputPorts ( ) const
inline

Definition at line 554 of file SimpleNode.hpp.

Referenced by dw::framework::SimpleNodeT< T >::validate().

◆ getRegisteredOutputPorts()

const dw::core::HeapHashMap< size_t, std::shared_ptr< ManagedPortOutputBase > > & dw::framework::SimpleNode::getRegisteredOutputPorts ( ) const
inline

Definition at line 559 of file SimpleNode.hpp.

Referenced by dw::framework::SimpleNodeT< T >::validate().

◆ initInputArrayPort()

template<typename NodeT , size_t PortIndex, typename... Args>
void dw::framework::SimpleNode::initInputArrayPort ( size_t  arrayIndex,
Args &&...  args 
)
inline

Initialize one ManagedPortInput of an array which will be owned by the base class and can be retrieved using getInputPort(size_t).

The method should be called instead of dw::framework::SimpleNode::initInputArrayPorts, if ports of the array need to be initialized with different args.

The macro NODE_INIT_INPUT_ARRAY_PORT can be used for convenience to hide the template parameters of this method.

Definition at line 347 of file SimpleNode.hpp.

References dw::framework::descriptorPortSize().

◆ initInputArrayPorts()

template<typename NodeT , size_t PortIndex, typename... Args>
void dw::framework::SimpleNode::initInputArrayPorts ( Args &&...  args)
inline

Initialize an array of ManagedPortInput which will be owned by the base class and can be retrieved using getInputPort(size_t).

All ports of the array are initialized with the same args. If ports of the array need to be initialized with different args use dw::framework::SimpleNode::initInputArrayPort instead.

The macro NODE_INIT_INPUT_ARRAY_PORTS can be used for convenience to hide the template parameters of this method.

Definition at line 330 of file SimpleNode.hpp.

◆ initInputPort()

template<typename NodeT , size_t PortIndex, typename... Args>
void dw::framework::SimpleNode::initInputPort ( Args &&...  args)
inline

Initialize a ManagedPortInput which will be owned by the base class and can be retrieved using getInputPort().

The macro NODE_INIT_INPUT_PORT can be used for convenience to hide the template parameters of this method.

Definition at line 310 of file SimpleNode.hpp.

◆ initOutputArrayPort()

template<typename NodeT , size_t PortIndex, typename... Args>
void dw::framework::SimpleNode::initOutputArrayPort ( size_t  arrayIndex,
Args &&...  args 
)
inline

Initialize one ManagedPortOutput of an array which will be owned by the base class and can be retrieved using getOutputPort(size_t).

The method should be called instead of dw::framework::SimpleNode::initOutputArrayPorts, if ports of the array need to be initialized with different args.

The macro NODE_INIT_OUTPUT_ARRAY_PORT can be used for convenience to hide the template parameters of this method.

Definition at line 405 of file SimpleNode.hpp.

References dw::framework::descriptorPortSize().

◆ initOutputArrayPorts()

template<typename NodeT , size_t PortIndex, typename... Args>
void dw::framework::SimpleNode::initOutputArrayPorts ( Args &&...  args)
inline

Initialize an array of ManagedPortOutput which will be owned by the base class and can be retrieved using getOutputPort(size_t).

All ports of the array are initialized with the same args. If ports of the array need to be initialized with different args use dw::framework::SimpleNode::initOutputArrayPort instead.

The macro NODE_INIT_OUTPUT_ARRAY_PORTS can be used for convenience to hide the template parameters of this method.

Definition at line 388 of file SimpleNode.hpp.

◆ initOutputPort()

template<typename NodeT , size_t PortIndex, typename... Args>
void dw::framework::SimpleNode::initOutputPort ( Args &&...  args)
inline

Initialize a ManagedPortOutput which will be owned by the base class and can be retrieved using getOutputPort().

The macro NODE_INIT_OUTPUT_PORT can be used for convenience to hide the template parameters of this method.

Definition at line 368 of file SimpleNode.hpp.

◆ iterateManagedInputPorts()

template<typename Func >
void dw::framework::SimpleNode::iterateManagedInputPorts ( Func  func)
inline

Definition at line 157 of file SimpleNode.hpp.

References iteratePorts(), and m_inputPorts.

◆ iterateManagedOutputPorts()

template<typename Func >
void dw::framework::SimpleNode::iterateManagedOutputPorts ( Func  func)
inline

Definition at line 171 of file SimpleNode.hpp.

◆ iteratePorts()

template<typename Func , typename PortList >
void dw::framework::SimpleNode::iteratePorts ( PortList &  portList,
Func  func 
)
inline

Definition at line 148 of file SimpleNode.hpp.

Referenced by iterateManagedInputPorts().

◆ registerPass() [1/2]

template<typename NodeT , size_t PassIndex, typename PassFunctionT >
void dw::framework::SimpleNode::registerPass ( PassFunctionT  func,
cudaStream_t const  cudaStream,
std::initializer_list< std::pair< dwStatus, uint32_t > > const &  returnMapping = {} 
)
inlineprotected

Register a GPU pass function and a cuda stream with the node base class.

The macro NODE_REGISTER_PASS can be used for convenience to hide the template parameters of this method.

Definition at line 250 of file SimpleNode.hpp.

◆ registerPass() [2/2]

template<typename NodeT , size_t PassIndex, typename PassFunctionT >
void dw::framework::SimpleNode::registerPass ( PassFunctionT  func,
std::initializer_list< std::pair< dwStatus, uint32_t > > const &  returnMapping = {} 
)
inlineprotected

Register a pass function with the node base class.

The macro NODE_REGISTER_PASS can be used for convenience to hide the template parameters of this method.

Note that the processorType DLA_0 and DLA_1 will be replaced by DLA when STM support cuDLA and dw deprecated them Issue tracked in AVCGF-569

Definition at line 223 of file SimpleNode.hpp.

◆ reset()

dwStatus dw::framework::SimpleNode::reset ( )
inlineoverridevirtual

Implements dw::framework::Node.

Reimplemented in dw::framework::SimpleNodeT< T >.

Definition at line 92 of file SimpleNode.hpp.

◆ resetPorts()

void dw::framework::SimpleNode::resetPorts ( )
overridevirtual

Default implementation to reset ports managed by the base class.

Call ManagedPortInput::reset on all input ports. This method is used by SimpleNodeT::reset.

Implements dw::framework::Node.

Referenced by dw::framework::SimpleNodeT< T >::reset().

◆ run()

dwStatus dw::framework::SimpleNode::run ( )
overridevirtual

Implements dw::framework::Node.

◆ runPass()

dwStatus dw::framework::SimpleNode::runPass ( size_t  passIndex)
overridevirtual

Implements dw::framework::Node.

◆ setInputChannel()

dwStatus dw::framework::SimpleNode::setInputChannel ( ChannelObject channel,
size_t  portID 
)
overridevirtual

Associate an input port with a channel instances.

A concrete node shouldn't need to override this method if all input ports are initialized in the constructor using the macros like NODE_INIT_INPUT_PORT.

Implements dw::framework::Node.

◆ setIterationCount()

dwStatus dw::framework::SimpleNode::setIterationCount ( uint32_t  iterationCount)
overridevirtual

Sets the node's iteration count. The value set can be retrieved with getIterationCount.

Implements dw::framework::Node.

◆ setModuleHandle()

template<typename ModuleHandle_t >
dwStatus dw::framework::SimpleNode::setModuleHandle ( ModuleHandle_t  handle,
dwContextHandle_t  context 
)
inline

Definition at line 185 of file SimpleNode.hpp.

◆ setName()

dwStatus dw::framework::SimpleNode::setName ( const char *  name)
finalvirtual

Implements dw::framework::Node.

◆ setNodePeriod()

dwStatus dw::framework::SimpleNode::setNodePeriod ( uint32_t  period)
overridevirtual

Sets the node's period The value set can be retrieved with getNodePeriod.

Implements dw::framework::Node.

◆ setObjectHandle()

virtual dwStatus dw::framework::SimpleNode::setObjectHandle ( dwModuleHandle_t  handle)
virtual

◆ setOutputChannel()

dwStatus dw::framework::SimpleNode::setOutputChannel ( ChannelObject channel,
size_t  portID 
)
overridevirtual

Associate an output port with a channel instances.

A concrete node shouldn't need to override this method if all output ports are initialized in the constructor using the macros like NODE_INIT_OUTPUT_PORT.

Implements dw::framework::Node.

◆ setState()

dwStatus dw::framework::SimpleNode::setState ( const char *  state)
inlineoverridevirtual

Set the current state. Override setState to handle state changes

Implements dw::framework::Node.

Definition at line 570 of file SimpleNode.hpp.

◆ setup()

dwStatus dw::framework::SimpleNode::setup ( )

Default implementation of the setup pass.

Check that all ports which are bound to a channel have a buffer available. This method is used by SimpleNodeT::setupImpl.

Referenced by dw::framework::SimpleNodeT< T >::setupImpl().

◆ teardown()

dwStatus dw::framework::SimpleNode::teardown ( )

Default implementation of the teardown pass.

Call ManagedPortInput::release on all input ports. This method is used by SimpleNodeT::teardownImpl.

Referenced by dw::framework::SimpleNodeT< T >::teardownImpl().

◆ updateCurrentErrorSignal()

dwStatus dw::framework::SimpleNode::updateCurrentErrorSignal ( dwGraphErrorSignal signal)
overridevirtual

A function that allows user override to update error signal It is automatically called by dwFramework when getErrorSignal is called and when pass returns non-success return code.

Parameters
[in,out]signalthat the node owner modifies to store current health. It is pre-filled with the latest module health signal
Returns
DW_SUCCESS

Implements dw::framework::Node.

◆ updateCurrentHealthSignal()

dwStatus dw::framework::SimpleNode::updateCurrentHealthSignal ( dwGraphHealthSignal signal)
overridevirtual

A function that allows user override to update health signal It is automatically called by dwFramework during teardown and when pass returns non-success return code.

Parameters
[in,out]signalthat the node owner modifies to store current health. It is pre-filled with the latest module health signal
Returns
DW_SUCCESS

Implements dw::framework::Node.

◆ updateHealthSignal()

dwStatus dw::framework::SimpleNode::updateHealthSignal ( const dwGraphHealthSignal signal)

Adds the provided Health Signal to the Health Signal Array. If the array is full, the new signal will not be added.

Parameters
[in]signalThe Health Signal to add
Returns
DW_SUCCESS, or DW_BUFFER_FULL if the array is currently full.

◆ validate() [1/2]

dwStatus dw::framework::SimpleNode::validate ( )
inlineoverridevirtual

Implements dw::framework::Node.

Reimplemented in dw::framework::SimpleNodeT< T >.

Definition at line 115 of file SimpleNode.hpp.

Referenced by dw::framework::SimpleNodeT< T >::validate().

◆ validate() [2/2]

dwStatus dw::framework::SimpleNode::validate ( const char *  direction,
const PortCollectionDescriptor collection,
dw::core::Function< bool(size_t)>  isPortBound 
)

Helper function used by dw::framework::SimpleNodeT::validate.

A concrete node shouldn't need to override or call this method.

Member Data Documentation

◆ m_asyncResetFlag

std::atomic<bool> dw::framework::SimpleNode::m_asyncResetFlag
protected

Definition at line 580 of file SimpleNode.hpp.

◆ m_inputPorts

dw::core::HeapHashMap<size_t, std::shared_ptr<ManagedPortInputBase> > dw::framework::SimpleNode::m_inputPorts
protected

Definition at line 577 of file SimpleNode.hpp.

Referenced by iterateManagedInputPorts().

◆ m_outputPorts

dw::core::HeapHashMap<size_t, std::shared_ptr<ManagedPortOutputBase> > dw::framework::SimpleNode::m_outputPorts
protected

Definition at line 578 of file SimpleNode.hpp.


The documentation for this class was generated from the following file: