Class: Taketo::Actions::Matches
- Inherits:
-
BaseAction
- Object
- BaseAction
- Taketo::Actions::Matches
- Defined in:
- lib/taketo/actions/matches.rb
Instance Attribute Summary
Attributes inherited from BaseAction
Instance Method Summary collapse
-
#initialize(options) ⇒ Matches
constructor
A new instance of Matches.
- #run ⇒ Object
Methods inherited from BaseAction
Constructor Details
#initialize(options) ⇒ Matches
Returns a new instance of Matches.
11 12 13 14 15 16 17 18 19 20 |
# File 'lib/taketo/actions/matches.rb', line 11 def initialize() super @resolver = if [:list] GroupResolver elsif [:view] NodeResolver else ServerResolver end.new(config, destination_path) end |
Instance Method Details
#run ⇒ Object
22 23 24 |
# File 'lib/taketo/actions/matches.rb', line 22 def run puts DestinationMatcher.new(@resolver.nodes).matches.join(" ") end |