Class: DevelopWithPassion::Expander::Copy
- Defined in:
- lib/developwithpassion_expander/copy.rb
Instance Method Summary collapse
-
#initialize(copy_target) ⇒ Copy
constructor
A new instance of Copy.
- #register(folder, copy_containing_folder = false) ⇒ Object
Constructor Details
#initialize(copy_target) ⇒ Copy
Returns a new instance of Copy.
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/developwithpassion_expander/copy.rb', line 4 def initialize(copy_target) array :sources do|a| a.read_and_write a.mutator :folder do|item| register(item,true) end a.mutator :contents do|item| register(item,false) end a.mutator :all_contents_in do|set_of_folders| set_of_folders.each{|item| contents(item)} end a.mutator :all_folders_in do|set_of_folders| set_of_folders.each{|item| folder(item)} end a.process_using :run, copy_target end end |