def __init__(self, aml, message, message_format=NORMALIZED):
        """
        Initialize a new Message instance
        :param aml: The parent AgentML instance
        :type  aml: AgentML

        :param message: The message being parsed
        :type  message: str

        :param message_format: The message format to return when the object is interpreted as a string
        :type  message_format: str
        """
        self._log = logging.getLogger('agentml.message')
        self._format = message_format
        self.aml = aml

        # Parsed (and un-parsed) message containers
        self._log.debug('Parsing raw message: {message}'.format(message=message))
        messages = self.aml.parse_substitutions((normalize(message), normalize(message, preserve_case=True), message))
        self._messages = {
            'normalized_message': messages[0],
            'case_preserved_message': messages[1],
            'raw_message': messages[2]
        }
        self._log.debug('Normalized message processed: {msg}'.format(msg=self._messages['normalized_message']))
        self._log.debug('Case preserved message processed: {msg}'.format(msg=self._messages['case_preserved_message']))
        self._log.debug('Raw message processed: {msg}'.format(msg=self._messages['raw_message']))
def __init__ ( self , aml , message , message_format = NORMALIZED ) : self . _log = logging . getLogger ( 'agentml.message' ) self . _format = message_format self . aml = aml self . _log . debug ( 'Parsing raw message: {message}' . format ( message = message ) ) messages = self . aml . parse_substitutions ( ( normalize ( message ) , normalize ( message , preserve_case = True ) , message ) ) self . _messages = { 'normalized_message' : messages [ 0 ] , 'case_preserved_message' : messages [ 1 ] , 'raw_message' : messages [ 2 ] } self . _log . debug ( 'Normalized message processed: {msg}' . format ( msg = self . _messages [ 'normalized_message' ] ) ) self . _log . debug ( 'Case preserved message processed: {msg}' . format ( msg = self . _messages [ 'case_preserved_message' ] ) ) self . _log . debug ( 'Raw message processed: {msg}' . format ( msg = self . _messages [ 'raw_message' ] ) )
Initialize a new Message instance
        :param aml: The parent AgentML instance
        :type  aml: AgentML

        :param message: The message being parsed
        :type  message: str

        :param message_format: The message format to return when the object is interpreted as a string
        :type  message_format: str