System Message

Author: Changbeom Choi (@cbchoi) Copyright (c) 2014-2020 Handong Global University Copyright (c) 2021-2024 Hanbat National University License: MIT. The full license text is available at: https://github.com/eventsim/pyjevsim/blob/main/LICENSE

This module contains an object SysMessage for handling messages (port and data) between Models.

class pyjevsim.system_message.SysMessage(src_name='', dst_name='')[source]

Bases: SystemObject

SysMessage for handling messages(port and data) between Models.

extend(_list)[source]

Extends the message list with multiple messages.

Parameters:

_list (list) – The list of messages to add

get_dst()[source]

Returns the destination(port) name of the message.

Returns:

The destination(port) name

Return type:

str

get_msg_time()[source]

Returns the message time.

Returns:

The message time

Return type:

float

get_src()[source]

Returns the source(model) name of the message.

Returns:

The source name

Return type:

str

insert(msg)[source]

Inserts a message into the message list(data).

Parameters:

msg (any) – The message to insert

retrieve()[source]

Retrieves the list of messages.

Returns:

The list of messages

Return type:

list

set_msg_time(_time)[source]

Sets the message time.

Parameters:

_time (float) – The time to set