Class: Leftovers::Processors::SetDefaultPrivacy

Inherits:
Object
  • Object
show all
Includes:
ComparableInstance
Defined in:
lib/leftovers/processors/set_default_privacy.rb

Instance Method Summary collapse

Methods included from ComparableInstance

#eql?, #hash

Constructor Details

#initialize(to) ⇒ SetDefaultPrivacy

Returns a new instance of SetDefaultPrivacy.



8
9
10
11
12
# File 'lib/leftovers/processors/set_default_privacy.rb', line 8

def initialize(to)
  @to = to

  freeze
end

Instance Method Details

#process(_str, _current_node, _matched_node, acc) ⇒ Object



14
15
16
# File 'lib/leftovers/processors/set_default_privacy.rb', line 14

def process(_str, _current_node, _matched_node, acc)
  acc.default_method_privacy = @to
end