Class: Rafflesia::ArchiveInventoryData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::ArchiveInventoryData
- Defined in:
- lib/rafflesia/artifacts/archive_inventory_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ archive_format: :archive_format, directory_count: :directory_count, extract: :extract, extracted_count: :extracted_count, file_count: :file_count, include_extensions: :include_extensions, include_path_substrings: :include_path_substrings, inventory_object: :inventory_object, inventory_path: :inventory_path, max_extracted_members: :max_extracted_members, max_member_bytes: :max_member_bytes, member_count: :member_count, members: :members, object_id: :object_id, output_dir: :output_dir, phase_timings_ms: :phase_timings_ms, skipped_extraction_count: :skipped_extraction_count, table_object: :table_object, table_path: :table_path, total_compressed_bytes: :total_compressed_bytes, total_uncompressed_bytes: :total_uncompressed_bytes }.freeze
Instance Attribute Summary collapse
-
#archive_format ⇒ Object
Returns the value of attribute archive_format.
-
#directory_count ⇒ Object
Returns the value of attribute directory_count.
-
#extract ⇒ Object
Returns the value of attribute extract.
-
#extracted_count ⇒ Object
Returns the value of attribute extracted_count.
-
#file_count ⇒ Object
Returns the value of attribute file_count.
-
#include_extensions ⇒ Object
Returns the value of attribute include_extensions.
-
#include_path_substrings ⇒ Object
Returns the value of attribute include_path_substrings.
-
#inventory_object ⇒ Object
Returns the value of attribute inventory_object.
-
#inventory_path ⇒ Object
Returns the value of attribute inventory_path.
-
#max_extracted_members ⇒ Object
Returns the value of attribute max_extracted_members.
-
#max_member_bytes ⇒ Object
Returns the value of attribute max_member_bytes.
-
#member_count ⇒ Object
Returns the value of attribute member_count.
-
#members ⇒ Object
Returns the value of attribute members.
-
#object_id ⇒ Object
Returns the value of attribute object_id.
-
#output_dir ⇒ Object
Returns the value of attribute output_dir.
-
#phase_timings_ms ⇒ Object
Returns the value of attribute phase_timings_ms.
-
#skipped_extraction_count ⇒ Object
Returns the value of attribute skipped_extraction_count.
-
#table_object ⇒ Object
Returns the value of attribute table_object.
-
#table_path ⇒ Object
Returns the value of attribute table_path.
-
#total_compressed_bytes ⇒ Object
Returns the value of attribute total_compressed_bytes.
-
#total_uncompressed_bytes ⇒ Object
Returns the value of attribute total_uncompressed_bytes.
Instance Method Summary collapse
-
#initialize(json) ⇒ ArchiveInventoryData
constructor
A new instance of ArchiveInventoryData.
Constructor Details
#initialize(json) ⇒ ArchiveInventoryData
Returns a new instance of ArchiveInventoryData.
55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 55 def initialize(json) super() hash = self.class.normalize(json) @archive_format = hash[:archive_format] @directory_count = hash[:directory_count] @extract = hash[:extract] @extracted_count = hash[:extracted_count] @file_count = hash[:file_count] @include_extensions = (hash[:include_extensions] || []) @include_path_substrings = (hash[:include_path_substrings] || []) @inventory_object = hash[:inventory_object] ? Rafflesia::ObjectRef.new(hash[:inventory_object]) : nil @inventory_path = hash[:inventory_path] @max_extracted_members = hash[:max_extracted_members] @max_member_bytes = hash[:max_member_bytes] @member_count = hash[:member_count] @members = (hash[:members] || []).map { |item| item ? Rafflesia::ArchiveMemberRecord.new(item) : nil } @object_id = hash[:object_id] @output_dir = hash[:output_dir] @phase_timings_ms = hash[:phase_timings_ms] || {} @skipped_extraction_count = hash[:skipped_extraction_count] @table_object = hash[:table_object] ? Rafflesia::ObjectRef.new(hash[:table_object]) : nil @table_path = hash[:table_path] @total_compressed_bytes = hash[:total_compressed_bytes] @total_uncompressed_bytes = hash[:total_uncompressed_bytes] end |
Instance Attribute Details
#archive_format ⇒ Object
Returns the value of attribute archive_format.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def archive_format @archive_format end |
#directory_count ⇒ Object
Returns the value of attribute directory_count.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def directory_count @directory_count end |
#extract ⇒ Object
Returns the value of attribute extract.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def extract @extract end |
#extracted_count ⇒ Object
Returns the value of attribute extracted_count.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def extracted_count @extracted_count end |
#file_count ⇒ Object
Returns the value of attribute file_count.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def file_count @file_count end |
#include_extensions ⇒ Object
Returns the value of attribute include_extensions.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def include_extensions @include_extensions end |
#include_path_substrings ⇒ Object
Returns the value of attribute include_path_substrings.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def include_path_substrings @include_path_substrings end |
#inventory_object ⇒ Object
Returns the value of attribute inventory_object.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def inventory_object @inventory_object end |
#inventory_path ⇒ Object
Returns the value of attribute inventory_path.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def inventory_path @inventory_path end |
#max_extracted_members ⇒ Object
Returns the value of attribute max_extracted_members.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def max_extracted_members @max_extracted_members end |
#max_member_bytes ⇒ Object
Returns the value of attribute max_member_bytes.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def max_member_bytes @max_member_bytes end |
#member_count ⇒ Object
Returns the value of attribute member_count.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def member_count @member_count end |
#members ⇒ Object
Returns the value of attribute members.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def members @members end |
#object_id ⇒ Object
Returns the value of attribute object_id.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def object_id @object_id end |
#output_dir ⇒ Object
Returns the value of attribute output_dir.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def output_dir @output_dir end |
#phase_timings_ms ⇒ Object
Returns the value of attribute phase_timings_ms.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def phase_timings_ms @phase_timings_ms end |
#skipped_extraction_count ⇒ Object
Returns the value of attribute skipped_extraction_count.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def skipped_extraction_count @skipped_extraction_count end |
#table_object ⇒ Object
Returns the value of attribute table_object.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def table_object @table_object end |
#table_path ⇒ Object
Returns the value of attribute table_path.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def table_path @table_path end |
#total_compressed_bytes ⇒ Object
Returns the value of attribute total_compressed_bytes.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def total_compressed_bytes @total_compressed_bytes end |
#total_uncompressed_bytes ⇒ Object
Returns the value of attribute total_uncompressed_bytes.
32 33 34 |
# File 'lib/rafflesia/artifacts/archive_inventory_data.rb', line 32 def total_uncompressed_bytes @total_uncompressed_bytes end |