Sha256: c66fae94f6691c5aa6c4ee920115504a9d9b2029a2ffffd2dc2b4a8c86547610

Contents?: true

Size: 384 Bytes

Versions: 9

Compression:

Stored size: 384 Bytes

Contents

module RelatonCalconnect
  class Hit < RelatonBib::Hit
    # Parse page.
    # @return [RelatonCalconnect::CcBliographicItem]
    def fetch
      # @fetch ||= Scrapper.parse_page @hit
      @fetch ||= begin
        url = "#{HitCollection::GHURL}#{@hit[:file]}"
        resp = Faraday.get url
        CcBibliographicItem.from_hash YAML.safe_load(resp.body)
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
relaton-calconnect-1.20.0 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.19.1 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.19.0 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.18.0 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.17.0 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.16.2 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.16.1 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.16.0 lib/relaton_calconnect/hit.rb
relaton-calconnect-1.14.2 lib/relaton_calconnect/hit.rb