forward

Forward message

Description

example

forward(message_in_name,message_out_name) forwards a valid input or local message to a local queue or an output port. After a chart forwards a message, it can remove another message from the queue in the same time step.

Examples

expand all

Check the input queue for message M_in. If a message is present, remove the message from the queue and forward it to the output port M_out.

Check the input queue for message M_in. If a message is present, forward the message to the local message queue M_local. After a delay of 0.3 seconds, transition from state A to state B, remove the message from the M_local message queue, and forward it to the output port M_out.

Introduced in R2018b