Class: ProteinAnnotation

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
lib/msf/models/protein_annotation.rb

Overview

ActiveRecord model of MSF ProteinAnnotation

Example:

ProteinAnnotation.first.description

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.primary_keyObject



10
11
12
# File 'lib/msf/models/protein_annotation.rb', line 10

def self.primary_key
  :ProteinAnnotationID
end

.table_nameObject



7
8
9
# File 'lib/msf/models/protein_annotation.rb', line 7

def self.table_name
  :ProteinAnnotations
end

Instance Method Details

#accessionObject



28
29
30
# File 'lib/msf/models/protein_annotation.rb', line 28

def accession
  self.description.split('|')[1]
end

#descriptionObject



22
23
24
# File 'lib/msf/models/protein_annotation.rb', line 22

def description
  self.Description
end

#description_hash_codeObject



19
20
21
# File 'lib/msf/models/protein_annotation.rb', line 19

def description_hash_code
  self.DescriptionHashCode
end

#protein_annotation_idObject



13
14
15
# File 'lib/msf/models/protein_annotation.rb', line 13

def protein_annotation_id
  self.ProteinAnnotationID
end

#protein_idObject



16
17
18
# File 'lib/msf/models/protein_annotation.rb', line 16

def protein_id
  self.ProteinID
end

#taxonomy_idObject



25
26
27
# File 'lib/msf/models/protein_annotation.rb', line 25

def taxonomy_id
  self.TaxonomyID
end