Sha256: 7f435ee28acc0fb70ceae3baa18aaeb87f4c17ad93b44159893a0f8962b232f1

Contents?: true

Size: 439 Bytes

Versions: 3

Compression:

Stored size: 439 Bytes

Contents

require "videos/version"
require "videos/tag_helpers"
require "videos/uri"
require "videos/video"
require "videos/youtube"
require "videos/youtube"
require "videos/vimeo"

module Videos
  PROVIDERS = {
    'youtube' => Videos::YouTube,
    'vimeo'   => Videos::Vimeo,
    'video'   => Videos::Video
  }

  def self.factory(uri_string,options={})
    uri = Videos::URI.new(uri_string)
    PROVIDERS[uri.provider].new(uri,options)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
rb42-videos-1.0.7 lib/videos.rb
rb42-videos-1.0.6 lib/videos.rb
rb42-videos-1.0.5 lib/videos.rb