Sha256: 8d5e87a835f59a927dfbbb1c32fdc40e822157e496d7137dbffa3bed38dfbcca
Contents?: true
Size: 599 Bytes
Versions: 3
Compression:
Stored size: 599 Bytes
Contents
module WaterDrop module Aspects # After method execution aspect # @example Apply after aspect to a method # WaterDrop::Aspects::AfterAspect.apply( # ClassName, # method: :run, # topic: 'karafka_topic', # message: ->(result) { "This is result of method run: #{result}" } # ) class AfterAspect < BaseAspect after options[:method], interception_arg: true do |interception, result, *args| options = interception.options interception.aspect.handle(self, options, args, options[:message], result) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
waterdrop-0.1.3 | lib/water_drop/aspects/after_aspect.rb |
waterdrop-0.1.1 | lib/water_drop/aspects/after_aspect.rb |
waterdrop-0.1.0 | lib/water_drop/aspects/after_aspect.rb |