Class: BEL::Nanopub::HashMapReferences

Inherits:
Object
  • Object
show all
Includes:
MapReferences
Defined in:
lib/bel/nanopub/hash_map_references.rb

Instance Method Summary collapse

Constructor Details

#initialize(annotation_reference_map, namespace_reference_map) ⇒ HashMapReferences

Returns a new instance of HashMapReferences.



8
9
10
11
12
13
14
# File 'lib/bel/nanopub/hash_map_references.rb', line 8

def initialize(annotation_reference_map, namespace_reference_map)
  @annotation_reference_map = annotation_reference_map
  @namespace_reference_map  = namespace_reference_map

  @annotation_references = annotation_reference_map.values.uniq
  @namespace_references  = namespace_reference_map.values.uniq
end

Instance Method Details

#annotation_referencesObject



16
17
18
# File 'lib/bel/nanopub/hash_map_references.rb', line 16

def annotation_references
  @annotation_references
end

#map_annotation_reference(reference) ⇒ Object



24
25
26
# File 'lib/bel/nanopub/hash_map_references.rb', line 24

def map_annotation_reference(reference)
  @annotation_reference_map[reference]
end

#map_namespace_reference(reference) ⇒ Object



28
29
30
# File 'lib/bel/nanopub/hash_map_references.rb', line 28

def map_namespace_reference(reference)
  @namespace_reference_map[reference]
end

#namespace_referencesObject



20
21
22
# File 'lib/bel/nanopub/hash_map_references.rb', line 20

def namespace_references
  @namespace_references
end