Class: Ensembl::Variation::AttribType

Inherits:
ModelBase show all
Defined in:
lib/ensembl/variation/activerecord.rb

Class Method Summary collapse

Methods included from PrimaryKeyOverrides

#primary_key

Methods included from TableNameOverrides

#table_name

Class Method Details

.key(value) ⇒ Object



74
75
76
# File 'lib/ensembl/variation/activerecord.rb', line 74

def self.key(value)
  mapping_hash.key(value)
end

.mapping_hashObject



70
71
72
# File 'lib/ensembl/variation/activerecord.rb', line 70

def self.mapping_hash
  @mapping_hash||={14=>:risk_allele,15=>:p_value,23=>:odds_ratio,24=>:beta}
end

.symbol(key) ⇒ Object



78
79
80
# File 'lib/ensembl/variation/activerecord.rb', line 78

def self.symbol(key)
  mapping_hash[key]
end