Class: Rafflesia::ResidueRange
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::ResidueRange
- Defined in:
- lib/rafflesia/proteins/residue_range.rb
Constant Summary collapse
- HASH_ATTRS =
{ chain_id: :chain_id, end: :end, start: :start }.freeze
Instance Attribute Summary collapse
-
#chain_id ⇒ Object
Returns the value of attribute chain_id.
-
#end ⇒ Object
Returns the value of attribute end.
-
#start ⇒ Object
Returns the value of attribute start.
Instance Method Summary collapse
-
#initialize(json) ⇒ ResidueRange
constructor
A new instance of ResidueRange.
Constructor Details
#initialize(json) ⇒ ResidueRange
Returns a new instance of ResidueRange.
19 20 21 22 23 24 25 |
# File 'lib/rafflesia/proteins/residue_range.rb', line 19 def initialize(json) super() hash = self.class.normalize(json) @chain_id = hash[:chain_id] @end = hash[:end] @start = hash[:start] end |
Instance Attribute Details
#chain_id ⇒ Object
Returns the value of attribute chain_id.
14 15 16 |
# File 'lib/rafflesia/proteins/residue_range.rb', line 14 def chain_id @chain_id end |
#end ⇒ Object
Returns the value of attribute end.
14 15 16 |
# File 'lib/rafflesia/proteins/residue_range.rb', line 14 def end @end end |
#start ⇒ Object
Returns the value of attribute start.
14 15 16 |
# File 'lib/rafflesia/proteins/residue_range.rb', line 14 def start @start end |