Class: Magick::Targeting::Group

Inherits:
Base
  • Object
show all
Defined in:
lib/magick/targeting/group.rb

Instance Method Summary collapse

Constructor Details

#initialize(group_name) ⇒ Group

Returns a new instance of Group.



6
7
8
# File 'lib/magick/targeting/group.rb', line 6

def initialize(group_name)
  @group_name = group_name.to_s
end

Instance Method Details

#matches?(context) ⇒ Boolean

Returns:

  • (Boolean)


10
11
12
# File 'lib/magick/targeting/group.rb', line 10

def matches?(context)
  context[:group]&.to_s == @group_name
end