Class: Concurrent::Actor::Behaviour::RemovesChild
- Defined in:
- lib/concurrent/actor/behaviour/removes_child.rb
Overview
Removes terminated children.
Instance Attribute Summary
Attributes inherited from Abstract
Instance Method Summary collapse
Methods inherited from Abstract
#broadcast, #initialize, #on_event, #pass, #reject_envelope
Methods included from InternalDelegations
#behaviour, #behaviour!, #children, #context, #dead_letter_routing, #log, #redirect, #terminate!, #terminated?
Methods included from PublicDelegations
#context_class, #executor, #name, #parent, #path, #reference
Methods included from TypeCheck
#Child!, #Child?, #Match!, #Match?, #Type!, #Type?
Constructor Details
This class inherits a constructor from Concurrent::Actor::Behaviour::Abstract
Instance Method Details
#on_envelope(envelope) ⇒ Object
6 7 8 9 10 11 12 |
# File 'lib/concurrent/actor/behaviour/removes_child.rb', line 6 def on_envelope(envelope) if envelope. == :remove_child core.remove_child envelope.sender else pass envelope end end |