Class: Rafflesia::StructurePrepareData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::StructurePrepareData
- Defined in:
- lib/rafflesia/proteins/structure_prepare_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ artifact_kind: :artifact_kind, artifact_schema_version: :artifact_schema_version, atom_count: :atom_count, chain_count: :chain_count, compressed_size_bytes: :compressed_size_bytes, content_type: :content_type, created_from_hash: :created_from_hash, encoding: :encoding, format: :format, parse_elapsed_ms: :parse_elapsed_ms, parser: :parser, prepared_object: :prepared_object, prepared_object_id: :prepared_object_id, raw_object: :raw_object, residue_count: :residue_count, schema_version: :schema_version, source: :source, source_metadata: :source_metadata, structure_id: :structure_id, target_id: :target_id, uncompressed_size_bytes: :uncompressed_size_bytes, was_object_already_prepared: :was_object_already_prepared, was_parsed_cache_hit: :was_parsed_cache_hit, was_prepared_record_hit: :was_prepared_record_hit, write_elapsed_ms: :write_elapsed_ms }.freeze
Instance Attribute Summary collapse
-
#artifact_kind ⇒ Object
Returns the value of attribute artifact_kind.
-
#artifact_schema_version ⇒ Object
Returns the value of attribute artifact_schema_version.
-
#atom_count ⇒ Object
Returns the value of attribute atom_count.
-
#chain_count ⇒ Object
Returns the value of attribute chain_count.
-
#compressed_size_bytes ⇒ Object
Returns the value of attribute compressed_size_bytes.
-
#content_type ⇒ Object
Returns the value of attribute content_type.
-
#created_from_hash ⇒ Object
Returns the value of attribute created_from_hash.
-
#encoding ⇒ Object
Returns the value of attribute encoding.
-
#format ⇒ Object
Returns the value of attribute format.
-
#parse_elapsed_ms ⇒ Object
Returns the value of attribute parse_elapsed_ms.
-
#parser ⇒ Object
Returns the value of attribute parser.
-
#prepared_object ⇒ Object
Returns the value of attribute prepared_object.
-
#prepared_object_id ⇒ Object
Returns the value of attribute prepared_object_id.
-
#raw_object ⇒ Object
Returns the value of attribute raw_object.
-
#residue_count ⇒ Object
Returns the value of attribute residue_count.
-
#schema_version ⇒ Object
Returns the value of attribute schema_version.
-
#source ⇒ Object
Returns the value of attribute source.
-
#source_metadata ⇒ Object
Returns the value of attribute source_metadata.
-
#structure_id ⇒ Object
Returns the value of attribute structure_id.
-
#target_id ⇒ Object
Returns the value of attribute target_id.
-
#uncompressed_size_bytes ⇒ Object
Returns the value of attribute uncompressed_size_bytes.
-
#was_object_already_prepared ⇒ Object
Returns the value of attribute was_object_already_prepared.
-
#was_parsed_cache_hit ⇒ Object
Returns the value of attribute was_parsed_cache_hit.
-
#was_prepared_record_hit ⇒ Object
Returns the value of attribute was_prepared_record_hit.
-
#write_elapsed_ms ⇒ Object
Returns the value of attribute write_elapsed_ms.
Instance Method Summary collapse
-
#initialize(json) ⇒ StructurePrepareData
constructor
A new instance of StructurePrepareData.
Constructor Details
#initialize(json) ⇒ StructurePrepareData
Returns a new instance of StructurePrepareData.
63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 63 def initialize(json) super() hash = self.class.normalize(json) @artifact_kind = hash[:artifact_kind] @artifact_schema_version = hash[:artifact_schema_version] @atom_count = hash[:atom_count] @chain_count = hash[:chain_count] @compressed_size_bytes = hash[:compressed_size_bytes] @content_type = hash[:content_type] @created_from_hash = hash[:created_from_hash] @encoding = hash[:encoding] @format = hash[:format] @parse_elapsed_ms = hash[:parse_elapsed_ms] @parser = hash[:parser] ? Rafflesia::StructureParserMetadata.new(hash[:parser]) : nil @prepared_object = hash[:prepared_object] ? Rafflesia::ObjectRef.new(hash[:prepared_object]) : nil @prepared_object_id = hash[:prepared_object_id] @raw_object = hash[:raw_object] ? Rafflesia::ObjectRef.new(hash[:raw_object]) : nil @residue_count = hash[:residue_count] @schema_version = hash[:schema_version] @source = hash[:source] @source_metadata = hash[:source_metadata] || {} @structure_id = hash[:structure_id] @target_id = hash[:target_id] @uncompressed_size_bytes = hash[:uncompressed_size_bytes] @was_object_already_prepared = hash[:was_object_already_prepared] @was_parsed_cache_hit = hash[:was_parsed_cache_hit] @was_prepared_record_hit = hash[:was_prepared_record_hit] @write_elapsed_ms = hash[:write_elapsed_ms] end |
Instance Attribute Details
#artifact_kind ⇒ Object
Returns the value of attribute artifact_kind.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def artifact_kind @artifact_kind end |
#artifact_schema_version ⇒ Object
Returns the value of attribute artifact_schema_version.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def artifact_schema_version @artifact_schema_version end |
#atom_count ⇒ Object
Returns the value of attribute atom_count.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def atom_count @atom_count end |
#chain_count ⇒ Object
Returns the value of attribute chain_count.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def chain_count @chain_count end |
#compressed_size_bytes ⇒ Object
Returns the value of attribute compressed_size_bytes.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def compressed_size_bytes @compressed_size_bytes end |
#content_type ⇒ Object
Returns the value of attribute content_type.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def content_type @content_type end |
#created_from_hash ⇒ Object
Returns the value of attribute created_from_hash.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def created_from_hash @created_from_hash end |
#encoding ⇒ Object
Returns the value of attribute encoding.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def encoding @encoding end |
#format ⇒ Object
Returns the value of attribute format.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def format @format end |
#parse_elapsed_ms ⇒ Object
Returns the value of attribute parse_elapsed_ms.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def parse_elapsed_ms @parse_elapsed_ms end |
#parser ⇒ Object
Returns the value of attribute parser.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def parser @parser end |
#prepared_object ⇒ Object
Returns the value of attribute prepared_object.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def prepared_object @prepared_object end |
#prepared_object_id ⇒ Object
Returns the value of attribute prepared_object_id.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def prepared_object_id @prepared_object_id end |
#raw_object ⇒ Object
Returns the value of attribute raw_object.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def raw_object @raw_object end |
#residue_count ⇒ Object
Returns the value of attribute residue_count.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def residue_count @residue_count end |
#schema_version ⇒ Object
Returns the value of attribute schema_version.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def schema_version @schema_version end |
#source ⇒ Object
Returns the value of attribute source.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def source @source end |
#source_metadata ⇒ Object
Returns the value of attribute source_metadata.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def @source_metadata end |
#structure_id ⇒ Object
Returns the value of attribute structure_id.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def structure_id @structure_id end |
#target_id ⇒ Object
Returns the value of attribute target_id.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def target_id @target_id end |
#uncompressed_size_bytes ⇒ Object
Returns the value of attribute uncompressed_size_bytes.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def uncompressed_size_bytes @uncompressed_size_bytes end |
#was_object_already_prepared ⇒ Object
Returns the value of attribute was_object_already_prepared.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def was_object_already_prepared @was_object_already_prepared end |
#was_parsed_cache_hit ⇒ Object
Returns the value of attribute was_parsed_cache_hit.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def was_parsed_cache_hit @was_parsed_cache_hit end |
#was_prepared_record_hit ⇒ Object
Returns the value of attribute was_prepared_record_hit.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def was_prepared_record_hit @was_prepared_record_hit end |
#write_elapsed_ms ⇒ Object
Returns the value of attribute write_elapsed_ms.
36 37 38 |
# File 'lib/rafflesia/proteins/structure_prepare_data.rb', line 36 def write_elapsed_ms @write_elapsed_ms end |