Class: Rafflesia::ResidueInterval
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::ResidueInterval
- Defined in:
- lib/rafflesia/proteins/residue_interval.rb
Constant Summary collapse
- HASH_ATTRS =
{ chain_id: :chain_id, end: :end, mean: :mean, 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.
-
#mean ⇒ Object
Returns the value of attribute mean.
-
#start ⇒ Object
Returns the value of attribute start.
Instance Method Summary collapse
-
#initialize(json) ⇒ ResidueInterval
constructor
A new instance of ResidueInterval.
Constructor Details
#initialize(json) ⇒ ResidueInterval
Returns a new instance of ResidueInterval.
21 22 23 24 25 26 27 28 |
# File 'lib/rafflesia/proteins/residue_interval.rb', line 21 def initialize(json) super() hash = self.class.normalize(json) @chain_id = hash[:chain_id] @end = hash[:end] @mean = hash[:mean] @start = hash[:start] end |
Instance Attribute Details
#chain_id ⇒ Object
Returns the value of attribute chain_id.
15 16 17 |
# File 'lib/rafflesia/proteins/residue_interval.rb', line 15 def chain_id @chain_id end |
#end ⇒ Object
Returns the value of attribute end.
15 16 17 |
# File 'lib/rafflesia/proteins/residue_interval.rb', line 15 def end @end end |
#mean ⇒ Object
Returns the value of attribute mean.
15 16 17 |
# File 'lib/rafflesia/proteins/residue_interval.rb', line 15 def mean @mean end |
#start ⇒ Object
Returns the value of attribute start.
15 16 17 |
# File 'lib/rafflesia/proteins/residue_interval.rb', line 15 def start @start end |