pyrtma.web_manager.Message
- class Message(header, data)[source]
Bases:
object
Message class
Contains message header and data
Methods
Generate a copy of a message structure
Create message object from JSON string
Generate formatted string for pretty printing of message
Convert message to dictionary
Convert message to JSON string
Attributes
name
type_id
- Parameters:
header (MessageHeader) –
data (MessageData) –
- classmethod from_json(s)[source]
Create message object from JSON string
- Parameters:
s (str) – JSON message string
- Raises:
InvalidMessageDefinition – JSON data does not match expected message defintion
- Returns:
Message object
- Return type: