Sha256: bd4c11a46c46953d522b2a7deb944780283993223a0bb9d927e4af3f587fe6ca
Contents?: true
Size: 582 Bytes
Versions: 3
Compression:
Stored size: 582 Bytes
Contents
module Relaton module Plateau class Hit def initialize(**args) @id = args[:id] @file = args[:file] end def bibitem return @bibitem if defined? @bibitem @bibitem = fetch_doc end private def fetch_doc resp = Net::HTTP.get_response URI("#{Bibliography::GHURL}#{@file}") return unless resp.is_a? Net::HTTPSuccess hash = YAML.load(resp.body) args = HashConverter.hash_to_bib hash args[:fetched] = Date.today.to_s BibItem.new(**args) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
relaton-plateau-1.20.0 | lib/relaton/plateau/hit.rb |
relaton-plateau-1.19.5 | lib/relaton/plateau/hit.rb |
relaton-plateau-1.19.4 | lib/relaton/plateau/hit.rb |