Class: Rafflesia::StructureEntityCandidate
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::StructureEntityCandidate
- Defined in:
- lib/rafflesia/proteins/structure_entity_candidate.rb
Constant Summary collapse
- HASH_ATTRS =
{ candidate_id: :candidate_id, chain_count: :chain_count, chain_ids: :chain_ids, entity_id: :entity_id, sequence_sha256: :sequence_sha_256, source: :source }.freeze
Instance Attribute Summary collapse
-
#candidate_id ⇒ Object
Returns the value of attribute candidate_id.
-
#chain_count ⇒ Object
Returns the value of attribute chain_count.
-
#chain_ids ⇒ Object
Returns the value of attribute chain_ids.
-
#entity_id ⇒ Object
Returns the value of attribute entity_id.
-
#sequence_sha_256 ⇒ Object
Returns the value of attribute sequence_sha_256.
-
#source ⇒ Object
Returns the value of attribute source.
Instance Method Summary collapse
-
#initialize(json) ⇒ StructureEntityCandidate
constructor
A new instance of StructureEntityCandidate.
Constructor Details
#initialize(json) ⇒ StructureEntityCandidate
Returns a new instance of StructureEntityCandidate.
25 26 27 28 29 30 31 32 33 34 |
# File 'lib/rafflesia/proteins/structure_entity_candidate.rb', line 25 def initialize(json) super() hash = self.class.normalize(json) @candidate_id = hash[:candidate_id] @chain_count = hash[:chain_count] @chain_ids = (hash[:chain_ids] || []) @entity_id = hash[:entity_id] @sequence_sha_256 = hash[:sequence_sha256] @source = hash[:source] end |
Instance Attribute Details
#candidate_id ⇒ Object
Returns the value of attribute candidate_id.
17 18 19 |
# File 'lib/rafflesia/proteins/structure_entity_candidate.rb', line 17 def candidate_id @candidate_id end |
#chain_count ⇒ Object
Returns the value of attribute chain_count.
17 18 19 |
# File 'lib/rafflesia/proteins/structure_entity_candidate.rb', line 17 def chain_count @chain_count end |
#chain_ids ⇒ Object
Returns the value of attribute chain_ids.
17 18 19 |
# File 'lib/rafflesia/proteins/structure_entity_candidate.rb', line 17 def chain_ids @chain_ids end |
#entity_id ⇒ Object
Returns the value of attribute entity_id.
17 18 19 |
# File 'lib/rafflesia/proteins/structure_entity_candidate.rb', line 17 def entity_id @entity_id end |
#sequence_sha_256 ⇒ Object
Returns the value of attribute sequence_sha_256.
17 18 19 |
# File 'lib/rafflesia/proteins/structure_entity_candidate.rb', line 17 def sequence_sha_256 @sequence_sha_256 end |
#source ⇒ Object
Returns the value of attribute source.
17 18 19 |
# File 'lib/rafflesia/proteins/structure_entity_candidate.rb', line 17 def source @source end |