Class: Verto::DSL::UpdateChangelog::FilteredBy::Proxy

Inherits:
Object
  • Object
show all
Defined in:
lib/verto/dsl/update_changelog/filtered_by.rb

Instance Method Summary collapse

Constructor Details

#initialize(filter_class, final_filter) ⇒ Proxy

Returns a new instance of Proxy.



18
19
20
21
# File 'lib/verto/dsl/update_changelog/filtered_by.rb', line 18

def initialize(filter_class, final_filter)
  @filter_class = filter_class
  @final_filter = final_filter
end

Instance Method Details

#call(*args) ⇒ Object



29
30
31
32
33
# File 'lib/verto/dsl/update_changelog/filtered_by.rb', line 29

def call(*args)
  filter_object
    .call(*args)
    .select { |message| @final_filter.match?(message) }
end

#newObject



23
24
25
26
27
# File 'lib/verto/dsl/update_changelog/filtered_by.rb', line 23

def new
  filter_object

  self
end