Class: Hermes::Serializer
- Inherits:
-
Object
- Object
- Hermes::Serializer
- Defined in:
- lib/hermes/serializer.rb
Instance Method Summary collapse
-
#initialize(clock: Hermes::DependenciesContainer["clock"]) ⇒ Serializer
constructor
A new instance of Serializer.
- #serialize(event_payload, version) ⇒ Object
Constructor Details
#initialize(clock: Hermes::DependenciesContainer["clock"]) ⇒ Serializer
Returns a new instance of Serializer.
8 9 10 |
# File 'lib/hermes/serializer.rb', line 8 def initialize(clock: Hermes::DependenciesContainer["clock"]) @clock = clock end |
Instance Method Details
#serialize(event_payload, version) ⇒ Object
12 13 14 |
# File 'lib/hermes/serializer.rb', line 12 def serialize(event_payload, version) event_payload.merge(meta: (version)) end |