Class: Retab::MaterializedDocument
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Retab::MaterializedDocument
- Defined in:
- lib/retab/workflow_test_run_results/materialized_document.rb
Constant Summary collapse
- HASH_ATTRS =
{ original_id: :original_id, filename: :filename, mime_type: :mime_type, gcs_uri: :gcs_uri, size_bytes: :size_bytes, content_fingerprint: :content_fingerprint }.freeze
Instance Attribute Summary collapse
-
#content_fingerprint ⇒ Object
Returns the value of attribute content_fingerprint.
-
#filename ⇒ Object
Returns the value of attribute filename.
-
#gcs_uri ⇒ Object
Returns the value of attribute gcs_uri.
-
#mime_type ⇒ Object
Returns the value of attribute mime_type.
-
#original_id ⇒ Object
Returns the value of attribute original_id.
-
#size_bytes ⇒ Object
Returns the value of attribute size_bytes.
Attributes inherited from Types::BaseModel
Instance Method Summary collapse
-
#initialize(json) ⇒ MaterializedDocument
constructor
A new instance of MaterializedDocument.
Methods inherited from Types::BaseModel
#inspect, normalize, #to_h, #to_json
Constructor Details
#initialize(json) ⇒ MaterializedDocument
Returns a new instance of MaterializedDocument.
25 26 27 28 29 30 31 32 33 |
# File 'lib/retab/workflow_test_run_results/materialized_document.rb', line 25 def initialize(json) hash = self.class.normalize(json) @original_id = hash[:original_id] @filename = hash[:filename] @mime_type = hash[:mime_type] @gcs_uri = hash[:gcs_uri] @size_bytes = hash[:size_bytes] @content_fingerprint = hash[:content_fingerprint] end |
Instance Attribute Details
#content_fingerprint ⇒ Object
Returns the value of attribute content_fingerprint.
17 18 19 |
# File 'lib/retab/workflow_test_run_results/materialized_document.rb', line 17 def content_fingerprint @content_fingerprint end |
#filename ⇒ Object
Returns the value of attribute filename.
17 18 19 |
# File 'lib/retab/workflow_test_run_results/materialized_document.rb', line 17 def filename @filename end |
#gcs_uri ⇒ Object
Returns the value of attribute gcs_uri.
17 18 19 |
# File 'lib/retab/workflow_test_run_results/materialized_document.rb', line 17 def gcs_uri @gcs_uri end |
#mime_type ⇒ Object
Returns the value of attribute mime_type.
17 18 19 |
# File 'lib/retab/workflow_test_run_results/materialized_document.rb', line 17 def mime_type @mime_type end |
#original_id ⇒ Object
Returns the value of attribute original_id.
17 18 19 |
# File 'lib/retab/workflow_test_run_results/materialized_document.rb', line 17 def original_id @original_id end |
#size_bytes ⇒ Object
Returns the value of attribute size_bytes.
17 18 19 |
# File 'lib/retab/workflow_test_run_results/materialized_document.rb', line 17 def size_bytes @size_bytes end |