Sha256: a15dd8fa4d2b871212ad1369077387a38324d813d8466a27120c74e783d8ddeb
Contents?: true
Size: 526 Bytes
Versions: 5
Compression:
Stored size: 526 Bytes
Contents
# frozen_string_literal: true module Alma class BibHolding extend Alma::ApiDefaults extend Forwardable def self.find(mms_id:, holding_id:) url = "#{bibs_base_path}/#{mms_id}/holdings/#{holding_id}" response = Net.get(url, headers:, timeout:) new(response) end attr_reader :holding def_delegators :holding, :[], :[]=, :has_key?, :keys, :to_json, :each def initialize(holding) @holding = holding end def holding_id holding["holding_id"] end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
alma-0.6.2 | lib/alma/bib_holding.rb |
alma-0.6.1 | lib/alma/bib_holding.rb |
alma-0.6.0 | lib/alma/bib_holding.rb |
alma-0.5.1 | lib/alma/bib_holding.rb |
alma-0.5.0 | lib/alma/bib_holding.rb |