Class: Rafflesia::FoldAlignData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::FoldAlignData
- Defined in:
- lib/rafflesia/proteins/fold_align_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ backend: :backend, hit: :hit, query_id: :query_id, residue_alignment: :residue_alignment, target_id: :target_id }.freeze
Instance Attribute Summary collapse
-
#backend ⇒ Object
Returns the value of attribute backend.
-
#hit ⇒ Object
Returns the value of attribute hit.
-
#query_id ⇒ Object
Returns the value of attribute query_id.
-
#residue_alignment ⇒ Object
Returns the value of attribute residue_alignment.
-
#target_id ⇒ Object
Returns the value of attribute target_id.
Instance Method Summary collapse
-
#initialize(json) ⇒ FoldAlignData
constructor
A new instance of FoldAlignData.
Constructor Details
#initialize(json) ⇒ FoldAlignData
Returns a new instance of FoldAlignData.
23 24 25 26 27 28 29 30 31 |
# File 'lib/rafflesia/proteins/fold_align_data.rb', line 23 def initialize(json) super() hash = self.class.normalize(json) @backend = hash[:backend] @hit = hash[:hit] ? Rafflesia::FoldHit.new(hash[:hit]) : nil @query_id = hash[:query_id] @residue_alignment = hash[:residue_alignment] ? Rafflesia::FoldResidueAlignment.new(hash[:residue_alignment]) : nil @target_id = hash[:target_id] end |
Instance Attribute Details
#backend ⇒ Object
Returns the value of attribute backend.
16 17 18 |
# File 'lib/rafflesia/proteins/fold_align_data.rb', line 16 def backend @backend end |
#hit ⇒ Object
Returns the value of attribute hit.
16 17 18 |
# File 'lib/rafflesia/proteins/fold_align_data.rb', line 16 def hit @hit end |
#query_id ⇒ Object
Returns the value of attribute query_id.
16 17 18 |
# File 'lib/rafflesia/proteins/fold_align_data.rb', line 16 def query_id @query_id end |
#residue_alignment ⇒ Object
Returns the value of attribute residue_alignment.
16 17 18 |
# File 'lib/rafflesia/proteins/fold_align_data.rb', line 16 def residue_alignment @residue_alignment end |
#target_id ⇒ Object
Returns the value of attribute target_id.
16 17 18 |
# File 'lib/rafflesia/proteins/fold_align_data.rb', line 16 def target_id @target_id end |