cloud_controller/lib/resource_pool/resource_pool.rb
# Adds everything under source directory +dir+ to the resource pool.
Adds everything under source directory +dir+ to the resource pool.
Adds everything under source directory + dir + to the resource pool .
def add_directory(dir)
    unless File.exists?(dir) && File.directory?(dir)
      raise ArgumentError, "Source directory #{dir} is not valid"
    end
    timed_section(logger, 'add_directory') do
      pattern = File.join(dir, '**', '*')
      Dir.glob(pattern, File::FNM_DOTMATCH).each do |path|
        add_path(path)
      end
    end
  end
def add_directory ( dir ) unless File . exists? ( dir ) && File . directory? ( dir ) raise ArgumentError , "Source directory #{dir} is not valid" end timed_section ( logger , 'add_directory' ) do pattern = File . join ( dir , '**' , '*' ) Dir . glob ( pattern , File :: FNM_DOTMATCH ) . each do | path | add_path ( path ) end end end
Adds everything under source directory +dir+ to the resource pool.
Adds everything under source directory + dir + to the resource pool .
dir