Method: MonkeyEngine::MonkeyService#add
- Defined in:
- lib/MonkeyService/monkey_service.rb
#add(monkey) ⇒ Object
Note:
Observers are notified after this operation in the form of these update method params: ObserverKlass#update(param1, param2, param3); where param1=Time of the operation, param2=Symbol representing the operation (in this case, :add), param3=The following Hash: [monkey] where monkey=The Monkey added.
Adds the Monkey to be managed.
40 41 42 43 |
# File 'lib/MonkeyService/monkey_service.rb', line 40 def add(monkey) @monkey_manager.add(monkey).start do_notify_observers(:add, { monkey: monkey }) end |