Class: StateChangeListener

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

Overview

Defines a template for a class that allows to be notified on state-changes in #ScriptExecutionState. A listener must be registered via #ScriptExecutionState::register_state_change_listener. When a state changes the method #state_changed is called.

Instance Method Summary collapse

Instance Method Details

#state_changed(state) ⇒ 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.

Raises:

  • (Exception)


10
11
12
# File 'lib/help/state_change_listener.rb', line 10

def state_changed(state)
  raise Exception.new("StateChangeListener: state change notification not implemented")
end