Class: ProgressMessageListener

Inherits:
Object
  • Object
show all
Defined in:
lib/help/progress_message_listener.rb

Overview

Defines a template for a class that allows to be notified about messages during script execution.A listener must be registered via #Ec2Script::register_state_change_listener. New messages are passed via the method #new_message.

Instance Method Summary collapse

Instance Method Details

#new_message(message, level = Logger::INFO) ⇒ Object

Method called when a state changes. Note: calls are synchronous, the listener should return quickly and handle more complicated routines in a different thread. The level corresponds to the logger.LEVEL and allows to signal the importance of a message

Raises:

  • (Exception)


11
12
13
# File 'lib/help/progress_message_listener.rb', line 11

def new_message(message, level = Logger::INFO)
  raise Exception.new("ProgressMessageListener: new message notification not implemented")
end