Class: Glue

Inherits:
Object
  • Object
show all
Defined in:
lib/glued/glue.rb

Instance Method Summary collapse

Constructor Details

#initialize(url) ⇒ Glue

Returns a new instance of Glue.



5
6
7
8
9
10
11
12
13
14
# File 'lib/glued/glue.rb', line 5

def initialize(url)
  raise "Invalid manifest url '#{url}' (it should end with .f4m)" unless url.to_s =~ /\.f4m$/ #Only by convention

  xml = Curl::Easy.perform(url).body
  manifest = F4M.new(url, xml)
  bootstrap = Bootstrap.new(manifest.bootstrap_info)
  grabber = Grabber.new(manifest, bootstrap)

  puts "\rComplete                                                                "
end