Class: Hiptest::NodeModifiers::DefaultArgumentAdder
- Inherits:
-
Object
- Object
- Hiptest::NodeModifiers::DefaultArgumentAdder
- Defined in:
- lib/hiptest-publisher/node_modifiers/call_arguments_adder.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(project) ⇒ DefaultArgumentAdder
constructor
A new instance of DefaultArgumentAdder.
- #update_all_calls ⇒ Object
- #update_calls ⇒ Object
- #update_uid_calls ⇒ Object
Constructor Details
#initialize(project) ⇒ DefaultArgumentAdder
Returns a new instance of DefaultArgumentAdder.
11 12 13 14 |
# File 'lib/hiptest-publisher/node_modifiers/call_arguments_adder.rb', line 11 def initialize(project) @project = project @indexer = ActionwordIndexer.new(project) end |
Class Method Details
.add(project) ⇒ Object
7 8 9 |
# File 'lib/hiptest-publisher/node_modifiers/call_arguments_adder.rb', line 7 def self.add(project) self.new(project).update_all_calls end |
Instance Method Details
#update_all_calls ⇒ Object
16 17 18 19 |
# File 'lib/hiptest-publisher/node_modifiers/call_arguments_adder.rb', line 16 def update_all_calls update_calls update_uid_calls end |
#update_calls ⇒ Object
21 22 23 24 25 |
# File 'lib/hiptest-publisher/node_modifiers/call_arguments_adder.rb', line 21 def update_calls @project.each_sub_nodes(Hiptest::Nodes::Call) do |call| update_call(call, @indexer.get_index(call.children[:actionword])) end end |
#update_uid_calls ⇒ Object
27 28 29 30 31 |
# File 'lib/hiptest-publisher/node_modifiers/call_arguments_adder.rb', line 27 def update_uid_calls @project.each_sub_nodes(Hiptest::Nodes::UIDCall) do |uid_call| update_call(uid_call, @indexer.get_uid_index(uid_call.children[:uid])) end end |