Class: Bulbasaur::ExtractImagesFromMeta
- Inherits:
-
Object
- Object
- Bulbasaur::ExtractImagesFromMeta
- Defined in:
- lib/bulbasaur/extracts/extract_images_from_meta.rb
Constant Summary collapse
- PROPERTY =
'og:image'
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(html) ⇒ ExtractImagesFromMeta
constructor
A new instance of ExtractImagesFromMeta.
Constructor Details
#initialize(html) ⇒ ExtractImagesFromMeta
Returns a new instance of ExtractImagesFromMeta.
5 6 7 |
# File 'lib/bulbasaur/extracts/extract_images_from_meta.rb', line 5 def initialize(html) @html = html end |
Instance Method Details
#call ⇒ Object
9 10 11 12 13 |
# File 'lib/bulbasaur/extracts/extract_images_from_meta.rb', line 9 def call = Bulbasaur::ExtractMetaInformationsFromHTML.new(@html).call image_urls = ().map { || { url: [:value], source: 'meta' } } image_urls end |