Class: RMD::NCT::Getter::KeyFromPage

Inherits:
Base
  • Object
show all
Defined in:
lib/rmd/nct/getter/key_from_page.rb

Instance Attribute Summary

Attributes inherited from Base

#data_link, #errors, #url

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from RMD::NCT::Getter::Base

Instance Method Details

#fetchObject



8
9
10
11
12
13
14
# File 'lib/rmd/nct/getter/key_from_page.rb', line 8

def fetch
  if key && element
    @data_link = element.text.strip
  else
    @errors = "The page does not contain the key."
  end
end