Module: Aggro::Projection

Extended by:
ActiveSupport::Concern
Includes:
BindingDSL, EventDSL
Included in:
SagaStatus
Defined in:
lib/aggro/projection.rb

Overview

Public: Mixin to turn a PORO into an Aggro projection.

Instance Method Summary collapse

Methods included from EventDSL

#handles_event?

Methods included from BindingDSL

#bind

Instance Method Details

#initialize(id) ⇒ Object



9
10
11
12
# File 'lib/aggro/projection.rb', line 9

def initialize(id)
  @id = id
  Aggro.event_bus.subscribe(id, self)
end