Class: Inferno::Repositories::ValueSets

Inherits:
InMemoryRepository
  • Object
show all
Defined in:
lib/inferno/repositiories/value_sets.rb

Instance Method Summary collapse

Instance Method Details

#find(url) ⇒ Object



15
16
17
# File 'lib/inferno/repositiories/value_sets.rb', line 15

def find(url)
  super || raise(UnknownValueSetException, url)
end

#select_by_binding_strength(strengths) ⇒ Object



11
12
13
# File 'lib/inferno/repositiories/value_sets.rb', line 11

def select_by_binding_strength(strengths)
  all.select { |vs| strengths.include?(vs.strength) }
end

#select_by_url(urls) ⇒ Hash

Returns a Hash where the keys are vs urls and the values are vs.

Returns:

  • (Hash)

    a Hash where the keys are vs urls and the values are vs



7
8
9
# File 'lib/inferno/repositiories/value_sets.rb', line 7

def select_by_url(urls)
  all_by_id.slice(*urls)
end